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.
It's a @kompotiq's solution. I just refactored it.
It's the fastest solution.
clever but slow
This comment is hidden because it contains spoiler information about the solution
Map<int, int> -> Set
Ok!
Perfect! But it's slow!
This comment is hidden because it contains spoiler information about the solution
Cool!
But I'm not sure if
-~h
is better than(h + 1)
.(h % 2 ^ v % 2)
is perfect solution!(a / sqrt(2)).toInt() -> a ~/ sqrt2
This comment is hidden because it contains spoiler information about the solution
else if
Respect!
Sorry! I took @hrollin's code to experiment. And accidentally pressed Submit!
It's much faster!
This comment is hidden because it contains spoiler information about the solution
Loading more items...