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.
Like this one! Performant & readable. I didn't realize there's such relation between the leg length and the direction :)
Can you share your solution?
No need to 'use undefined'. It works perfectly if in the arrayShiftToEnd for loop the end condition is modified to i < array.length - 1
:)
I belive this is incorrect. Try calling score([1,1,1,1,1,1])
The first solution that I'm reading and that's easy to read/understand!
This comment is hidden because it contains spoiler information about the solution