Is it just me or is CodeWars.com insanely hard?

Check out this question. I am in Javascript, so naturally they give me a Ruby example:

In this kata, you must create a digital root function.

A digital root is the recursive sum of all the digits in a number. Given n, take the sum of the digits of n. If that value has two digits, continue reducing in this way until a single-digit number is produced. This is only applicable to the natural numbers.

Here's how it works (Ruby example given):

digital_root(16)
=> 1 + 6
=> 7

digital_root(942)
=> 9 + 4 + 2
=> 15 ...
=> 1 + 5
=> 6

digital_root(132189)
=> 1 + 3 + 2 + 1 + 8 + 9
=> 24 ...
=> 2 + 4
=> 6

digital_root(493193)
=> 4 + 9 + 3 + 1 + 9 + 3
=> 29 ...
=> 2 + 9
=> 11 ...
=> 1 + 1
=> 2

I'm not sure if they meant to put => or if that's some kind of internal error on their website, but I saw it in another question, too. I know => translates to => but I don't know if this is a Ruby convention or what. Like I said, this same thing => was in another question I just skipped, too.

/r/learnjavascript Thread Parent