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.
Would fail on "\n"
I think it is worth noting that
for ... of
would be an improvement in this context since we don't actually care what the index is for each element.for .. in
is perfectly well-defined for arrays, and it's a simplerfor
than the C-style one, at least in syntax ( which actually is important in the grand scheme of readability / maintainability ).Speed isn't everything. Also, don't try to out-optimise your compiler.
shortest one yet
bravo!
For/in loop isn't for arrays. It will be better to use a simple for. It will be faster at least…