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.
How did you come up with this solution?
cool
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Could you explain how it works, please?
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Could somebody explain how this works?
It doesn't work correctly for negative integers that end with 5. If num = -55 it will return -50, but not -60 as expected. That's because how Math.round works
It won't work for a long enough array though