Ad
  • Custom User Avatar

    Your code is wrong, print the input and figure out why. One of the things that are wrong in your code is, why are you saying that going twice in a direction should return False?

  • Default User Avatar

    There are random tests which are different with each running of the code. As for the test you just showed, what's quite likely is that you are misreading one test result for another in the the logs. For certain, this kata has been thoroughly vetted, and especially so in Python. Notice that over 18K people have solved it in python. If you want, you can post your code with a spoiler tag and use proper code markdown, so someone can maybe help you figure this out.

  • Custom User Avatar

    yes it works.

    hint: don't try to "reason" about the specs, just apply them precisely like they are given. You're currently trying to use shortcuts, and that's what makes your code fail. You're reinventing the specifications without realizing it. (edit: I was thinking about g964's kata, not this one, sorry 'x) )

    => what's your current problem exactly?

  • Default User Avatar

    also: don't forget to always use the spoiler tag when discussing code. (I have added the tag for you)

  • Default User Avatar

    the previous two posts were about the same thing: Py 2 vs. Py 3