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 comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Yes, you are right. I was hasty and submitted too early :(
This comment is hidden because it contains spoiler information about the solution
Thanks for your contribution. I would suggest adding a few simple tests for users to work with prior to submission.
Thanks for the heads up!
Yes, I was a little surprised that it passed all the tests.
Good point. The one-liner "best practice" might be sub-optimal in terms of asymptotic complexity. I think yours is O(n): O(n) (for split) + O(n) for the explicit loop. So the whole thing is still O(n). But the one-liner might be O(n**2) given the way min() is used.
I agree. This exercise seemed much easier than other 4kyu kata.