Ad
  • Custom User Avatar

    woah, okay. tried out what Chrono79 Suggested. got error and now I am confused. Any hints why could that be happening?
    Test Failed
    Expected string length 217 but was 230. Strings differ at index 147.
    Expected: "...9000000000000 + 70000000000 + 8000000000 + 50000000 + 3000..."
    But was: "...9000000000000 + 70000000000 + -4000000000 + -600000000 + 5..."
    ------------------------------------------------------------------^

    Also Tried this:
    Assert.That(Kata.ExpandedForm(60000000000000009), Is.EqualTo("60000000000000000 + 9"));

    Test Failed
    Expected string length 21 but was 65. Strings differ at index 20.
    Expected: "...0000000000000 + 9"
    But was: "...0000000000000 + 40000000 + -4000000 + -20000 + 200 + -40 + -5"
    ------------------------------^

  • Custom User Avatar

    How would we know if you don't say which language you are using and you don't show your code either?
    Post it here using proper markdown and marking your post as having spoiler content if you ask for help.

  • Custom User Avatar

    How is it that i am getting incorrect answer when i try my code here but correct when i run the same code in my computer?

  • Custom User Avatar

    Thanks, it was my code.

  • Custom User Avatar

    Can you please let me know there is an issue with the testing? Kata is in php. Thanks

  • Custom User Avatar

    testRandom
    Failed asserting that two strings are equal.
    Expected: '6000000000000000000 + 600000000000000000 + 60000000000000000 + 8000000000000000 + 500000000000000 + 70000000000000 + 9000000000000 + 70000000000 + 8000000000 + 50000000 + 3000000 + 800000 + 20000 + 2000 + 400 + 60 + 5'
    Actual : '6000000000000000000 + 600000000000000000 + 60000000000000000 + 8000000000000000 + 500000000000000 + 70000000000000 + 9000000000000 + 70000000000 + 8000000000 + 50000000 + 3000000 + 800000 + 20000 + 2000 + 400 + 20 + 5'
    How is that possible? Code passes all the other tests