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.
Math is the devil's work, I tell ya. /s
Probably a definition created for learning purposes, but true, it does not exist anywhere on the internet being used with an array besides here.
What does the description not tell you about how to solve the kata?
The description defines clearly what is expected. Notice that more than 1800 persons solved this kata and nobody complained about that before.
Most 4 kyu Katas I did were easier than even figuring out how to get started on solving this one...
100%
You forgot, I didn't even know! I'm learning a lot here
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Sorry that you feel frustrated about this kata.
The timeout happens because your algorithm might be of complexity
O(n^3)
or above.If you can reduce the complexity, the timeouts should go away.
You reduce the complexity, by eliminating/refactoring the number of
nested for-loops that might be in your code.
Tweak your logic that already works in the following manner to gain performance:
Instead of initiating the search for a substring with minimum size, start
with a substring of maximum size and work your way down.
Almost 2000+ (out of5000) have solved it, so can you. Go for it!
For real! I'm having trouble getting all the different combinations of the different towns.
This comment is hidden because it contains spoiler information about the solution