Ad
  • Custom User Avatar

    that was a tricky one i struggled alot, tip consider it like a snake

  • Custom User Avatar

    You can always print the input at the beginning of your function to see what might be causing the issue.

  • Custom User Avatar

    That was fun, i completed with only one loop. I seem to be enjoying these type of questions more, apparently. :)

  • Custom User Avatar

    It would be great to have more representative test samples. I got a timeout, so I assume the tests triggered an infinite loop, but there was no information about what caused it. I tested my code with lists from 3 to 10 items, and it worked fine, but now I have no idea how to fix it without knowing what went wrong. Are all the arrays in the test square?

  • Custom User Avatar

    Almost everything there is wrong. Starting with the function's name:

    def snail(snail_map):
        pass
    

    You should use the function's argument (snail_map), not some fixed value.

  • Custom User Avatar

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

  • Custom User Avatar

    Could you rename it into "Snail Traversal" in the description? Calling it "Snail Sort" is being sloppy with terms that have meaning and needlessly confusing. I just showed it to a friend, and they immediately fixated on this.

  • Custom User Avatar

    Test error when empty error. May be the test needs a correction.

  • Custom User Avatar

    Surprisingly fun kata, very enjoyed! The empty array in an array edge case input really confuses me. I was dissapointed when I got the whole thing working except for the empty array in an array test. I guess I don't really understand how to work with an array with only an empty array in it in Java.

  • Custom User Avatar

    I had already done more than half of the answer and it has not been saved ;(

  • Custom User Avatar

    finally solved it and each time i look at all the papers i used and how complex is my code i think i am a freaking genius , tht s all i ve to say

  • Custom User Avatar

    This is specified in the description:

    NOTE 2: The 0x0 (empty matrix) is represented as en empty array inside an array [[]].

  • Custom User Avatar

    Given an n x n array,

    Attempt gives [[]] which is not n x n (it is 0 x 1 array)

    No tests with n x m array. Please fix description

  • Custom User Avatar

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

  • Custom User Avatar

    Had a lot of fun !

  • Loading more items...