Ad
  • Custom User Avatar

    python new test framework is required. updated in this fork

  • Custom User Avatar

    Of course ! Pong basis ;)

  • Custom User Avatar

    And it's an excellent habit !

  • Custom User Avatar

    Not a very clean method ;) It's better to test is the indexes are valid.

  • Custom User Avatar

    So... After solving it, I must say the description is absolutely inconsistent. You need to stop parsing when the diagonal stops but there remains a row you did not parse, or when your reach on the right the length of the shortest row.

  • Custom User Avatar

    Description needs to add more explanations and examples to clarify when we are supposed to stop parsing the input string. For example in the second example of basic tests, it returns "BruuJ", "nothing on the bottom line, so parsing should end". However one could easily extend the result by continuing upright with "D", "H", etc., that is following the description ("The message ends when there is no space at the right up or down diagonal."). The same case could occur on the second diagonal if one line is shorter than others, so what are we supposed to do?

  • Custom User Avatar

    I agree with you, the description does not describe correctly what users are supposed to do.

  • Custom User Avatar

    Unfortunately, the problem statement only says that "[the] message ends when there is no space at the right up or down diagonal." Probably more examples, especially those clarifying possible edge cases, would help.

  • Custom User Avatar

    It's expecting string 'BruuJ', because in the matrix there is another row with letter 'K' in it. In order to continue decoding, it should go to the last row, but there's no letter at that index, so decoding must stop.

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    Hi everybody,

    I have a question regarding the random tests.

    Here's a random test string:

    B p E D y o q F q n C H v x K K D
    C r I y o w A n y F t B B q J C u B t z I A F I
    F H u s s y H I D n B
    L o J u F D F J A I s G s u o x E v
    L r x G J K y x o I E n w G H J M M z w F M r G
    K

    Here's the message I got:

    Expected: 'BruuJ', instead got: 'BruuJDHnqFBGwuHxMvz'

    I don't understand why 'BruuJDHnqFBGwuHxMvz' is incorrect, because as far as I can see you can easily bounce up and down from the first letter B to the last letter z. Maybe the author of the problem could clarify the problem statement.

    Cheers.

    P.S. I'm going to post my JavaScript code hidden under Spoiler in case someone would care to look into it. (Done!)

  • Default User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Default User Avatar

    thanks for taking your time!!!!!! means a lot yea ill try:)))

  • Custom User Avatar

    You're in the "right direction".

    Note that the length of the lines in the code is different, so you need to control IndexError.

    You can use print to debug your function. Try to understand and better control values of your variables on each loop iteration.

  • Default User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Loading more items...