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.
Yes. Exceptions shouldn't be used for flow control. In a real setting, you'd probably parse it as a long (and possibly catch that exception) then check the size for the actual type.
That being said, it is really easy to see what is happening, which is good.
And it looks pretty. :-)
Wouldn't the code be slower because of the try-catch check?
I like this idea too. the code is very clean
This comment is hidden because it contains spoiler information about the solution
Impotent to notice here this solution isn't performance-wise.
It allocates in memory lots of intermediate arrays. That might be costly and has to be avoided.
Your solution is using a library?
Why people are voting "Best Practice" to a String concat loop?
ну ты гнида
This comment is hidden because it contains spoiler information about the solution
It's possible to solve this problem in O(n*log(n)) time by reversing the keys and values of the second argument, and this is a O(n^2) solution.
It's my solution xD How dare you? Have a nice day
Such finesse! Being new to java myself, I didn't realize it had these tools to make this solution so succinct.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution