Ad
  • Custom User Avatar

    oh...
    my bad
    now I feel so embarassed

  • Custom User Avatar

    Why? Because you're returning incorrect results? You should always be returning single digit numbers, read the description again if it's not clear.

    (not (= 15 6))

    You're returning 15 and expected is 6.

  • Custom User Avatar

    WTF???

    Clojure tests:
    expected: (= (digital-root 456) 6)
    actual: (not (= 15 6))

    expected: (= (digital-root 195) 6)
    actual: (not (= 15 6))
    expected: (= (digital-root 992) 2)
    actual: (not (= 20 2))
    expected: (= (digital-root 999999999999) 9)
    actual: (not (= 108 9))
    expected: (= (digital-root 167346) 9)
    actual: (not (= 27 9))

    Thumb down