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.
Error on the author's part probably or how the assertions are run
This comment is hidden because it contains spoiler information about the solution
Smart !
I do the same.
Wow, that's genius. I tried to use regex but had no idea how. Thanks man!
Does a ternary operator not count as a conditional statement?
That's because you're returning the wrong thing.
My first thought with this Kata was to try absolute value. I knew though that your solution was what I would end up with.
It is fun to try and solve some Kata in an unorthodox way though.
no need for the Math.abs function since -number already gives the opposite value
Why you didn't use template literal?
Just completed the kata :) Thanks!
No problem!
Oh damn, silly me. :)
The top
Test.assertEquals(...)
line is for the previous set of array1 and array2. The arrays below are for the next set.Test.assertEquals(balance(array1, array2), false);
array1 = ["a","b","c","d","e","f","g","g"];
array2 = ["h","h","i","j","k","l","m","n"];
This is second example test.
It is "m" and "n", not 2 "m"s :)
Loading more items...