Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Well I feel silly after my in depth solution.
It ended up actually being my mistake, I had for(const char in s) instead of the correct for(const char of s)
For whatever reason, the tests are failing for JavaScript. My code is correct, this is an easy question, which I've verified outsie the codewars environment with the same test inputs.
This comment is hidden because it contains spoiler information about the solution