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.
There is a massive problem with
all-multiples-of-two
: it expects2, 4, 6, ...
instead of0, 2, 4, ...
(0
is a multiple of 2 too), and it only checks the first 2 values so[2, 4]
will also pass the tests.The kata doesn't explain what the functions required to be implemented are expected to do.
This issue could be clearer
I'm so sorry!
Please use spoiler flag next time, your post was visible in the homepage.
Seems you guys find an "a" number in the array that gives the formula answer.
I looped both "a" and "b" and gave timeout error :)
a * b + b
=> a * b + 1 * b
=> b * (a + 1)
// b is the common factor here.
a*b + b = 0
"b" goes in front of the brackets, causing the quation to look like:
b*(a+1) = 0
Thereforfe, ab+b = b(a+1)
How did we go from
a * b + b
tob * (a + 1)
??This fails at least for n equals 5, 15, 32, 90, 189, 527, 1104, 3074, 6437, 17919 and 37520, because it doesn't check a != b
No random tests.
The description explains nothing at all.
It's live for me.
nice, this is arithmetic progression, but I forget it
thank you I like this
Loading more items...