Ad
  • Custom User Avatar

    Oh. And.

    Please add random test cases.

  • Custom User Avatar

    I have taken the liberty of correcting some glaring spelling and logic errors in the description and the tests. Hope that's OK with you.

    What is the added value of testing for invalid inputs? It adds one line of code to the solution and it has absolutely nothing to do with the calculations. I would suggest testing with valid inputs only, and specifying such in the description.

    Also, operators apparently are placed between numbers only, and not in front of the first one. But we have to infer this from an example. It would be perfectly possible to have a - in front of the first number (and it might give more possible solutions). I would suggest explicitly specifying possible placement of operators in the description, not only that they don't go in front of the first number, but also what happens when to >= 10 - can we put + or - in the middle of 10 or 11, or not ?

    Otherwise - fun kata! I was worried the number of possible answers would get out of hand in a hurry, but that remained quite managable. Thanks! :]