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.
This comment is hidden because it contains spoiler information about the solution
This is just beautiful.
Ah, then that explains it.
This solution is still really elegant though. You could just regexing the string first without having to refactor the rest of the code.
This solution does not satisfy the whitespace criteria of the kata:
Why is there a forward slash in the substring replacement parameter? I don't see any syntax for it in MDN documentation.
Goddamn, that's beautiful
Thats's a pretty dramatic difference in performance.