Ad
  • Custom User Avatar

    It probably comes for the fact the Kata function MUST have an input of int and when you do int i = 000076 , C# delete the leading zero(s) and translate it to 76.
    So it need to be input as a string. In C# I believe, you cannot pad a number with previous zeros unless you gave it a format and make it a string (which goes again the int input so ...)

    The worst is that since the test could be (in theory) random, you cannot add leading zero(s) in your code with something like number.ToString("D5")

    If there is a way to keep leading zero inside the function I would be really interested in learning it. :D

  • Custom User Avatar

    I write in C#, please tell me, what makes below problem in random test?
    Test Failed
    Expected string length 5 but was 9. Strings differ at index 0.
    Expected: "Not!!"
    But was: "Jumping!!"