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.
chatGpt gave me same answer when i tried to find a better solution
im working on this solution some how i forgot to put'...' in front of arr
nice and beautiful solution!
omfg i did't even thought about it, its so obvious...
filter
won't sort the resulting array.filter tends to sort the resulting array which according to the instruction is not allowed.
I like this one. Mine was a bit longer heh.
This comment is hidden because it contains spoiler information about the solution
I like this solution) really the shortest you can find!!
This comment is hidden because it contains spoiler information about the solution
Cool functional approach, this is what I was looking for, but couldn't discover! +++1
No, splice is mutative. Never mutate when writing functional code, which is clearly what this problem is asking for.
This is what I got but you had better variable name.
Wouldn't splice mutate numbers?
Nice use of ES6 syntax here. +1 for not mutating the original array