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
I have exactly the same problem trying this in CoffeeScript. I'll create an issue for this.
Glad to have kept you stimulated up to a positive solution, then :)
Oh, I didn't know it: thanks for providing me such an info, but actually that should not be the bottleneck: try somewhere else :)
What's a "binary gcd"? You know there is a fast and good algo for the gcd, right?
As always, googling the problem should easily gives you the required pieces to solve the kata.
I fear that would be equivalent to give you the solution, sorry.
That does mean that the whole bunch of tests has to execute in less than 12s.
You'll have to optimized your code. ;)
Do not go for primes, you might find an even more plain and "famous" way of tackling this problem.
[And my sincerest kudos for your persistency after a few weeks: that's what makes a great coder!]
my solution is slow too(but it's enough to pass all the tests). a clever idea of this kata is related to binary ;-)
Do not brute force it and try to look for some more elegant mathematical solution.