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.
I used a really long winded recursion implementation and I feel so stupid looking at this
I was really struggling with the iterative solution, but this is so cool.
You could use a set, which I belive has constant lookup time too
very cool solution
Recursion doesn't mean worse time complexity.
Well, i tried not to use recursion (which means a worse time complexity) but failed because of "bananas". And finally i get the same solution with such a huge brunch of people.
But I still wonder a better algorithm. Can anyone find one?
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Can someone explain how this solution passes for example
I do not understand how it chooses the correct second
"a"
Same error here, please fix the test if possible.
This comment is hidden because it contains spoiler information about the solution
I'm also have this problem.
I am having the same thing happening to me (just saw this post after posting about it last night).
I have made the JS version but seems to have a problem on the last check.
My solution returns the correct values in ~300ms and I know they are the correct one because if I add one number more it always says the values is incorrect and the difference is that exact number.
With the right answer I just get the first test pass and in all the others I get:
Value is not what was expected
Could someone check that the tests are evaluating the right answers?
huh I always put {something} did not know i could {} for format. I will continue though some use of identifier's helps meh
Loading more items...