Ad
  • Custom User Avatar

    Solved the kata, my algorythm wasn't good.

  • Custom User Avatar

    I wrote the code with the simple and optimal solution. However, when I try to submit, I have the problem that it displays that it wants to remove from a 0 pile. I don't know what the problem can be, since when I run the function on my computer, with the given input, my computer displays the correct move.

    For example the error message: "Exception: Cannot remove 6 straws from board position 0 (which has 0 straws)
    Board state: (0, 6, 5, 5)" shows up. But when I run my function on [0,6,5,5], it returns (2,6) on my computer.

  • Custom User Avatar

    Thanks. Problem solved. Noob error.

  • Custom User Avatar

    Bit of a late reply, but when there are no wiring connections specified, none should be made. Any strings processed by that Plugboard would return unaltered.

  • Custom User Avatar

    Hard to say without more explanation or code, but it seems that your Plugboard's initialization function is raising your "Too many wires" error when it shouldn't. Try ensuring the logic is correct for when that error should be raised.

  • Custom User Avatar

    All 8 test passed, but there is an error message:
    Test usage
    Translate characters
    Traceback:
    in
    in init
    AssertionError: Too many wires

    I am new to Code Wars as well as python. Can you please tell me what's wrong?
    Btw "Too many wires" is an error I raise when there are more than 20 characters in wires.
    I also pass empty imput.