Ad
  • Default User Avatar

    You're welcome and thanks for your kind words.
    For sake of completeness, you should study iterative solutions such as DanillGodovan's one as they are also insanely fast/

  • Default User Avatar

    Extremely clever. Delightful, elegant solution. I'm going to study it, it will teach me lots.

    Thank you

  • Default User Avatar

    Very elegant solution, thanks for the lesson!

  • Default User Avatar

    Thank you for making me notice that, besides showing me the possible allowed directions in the various parts of the track, the examples also limited the allowed 'pieces' (characters) I can encounter there. I have to refine my parsing routine... Back to work!
    Francesco

  • Custom User Avatar

    it is allowed to go southwards, to 1, 22

    Is it? There are no examples of curves or straights in the Kata description that suggest that is possible.

  • Default User Avatar

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

  • Custom User Avatar

    Congrats for persevering and getting it to work.

  • Default User Avatar

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

  • Default User Avatar

    Thank you, Hobovsky! When I 'test' my solution, it passes all the game simulations but the last one.
    After that one test, my solution also passes the two "throw an error" tests.

    This game follows its rules in a strict sequence: if you miss a single step you will very probably miss all the
    following ones. I had some hard time in understanding all the subtle tricks of this kata, and maybe I still need to
    learn some of them. But if you can read the message I wrote, in which I posted a full trace of the program behaviour,
    you will be able to follow every part of it... and so I did, by hand, with pencil, paper and debugger!
    Well, it really doesn't seem to me it's a problem in my solution. My program follows strictly every rule I know of, and it succeeds in every test but this. I apologize with docgunthrop, but as far as I understand it seems a problem in the required output, not in my one!
    Ok, I am just a pupil, I have a lot yet to learn. But without some debugging from the teacher, I really can't go a single step further.
    Will you have some spare time and help me?

  • Custom User Avatar

    Maybe someone with some free time can help you debug your solution, but I don't have that luxury rn.

  • Custom User Avatar

    What exactly happens when you submit your solution? Does it return incorrect answers? Does it time out? Did you try to run it locally in your IDE with exactly the same inputs which it fails on Codewars? See here if you need to know how to recreate tests locally.

  • Default User Avatar

    I don't know if my previous comments on this kata were too stupid, or too boring, to deserve an answer...
    but I believe that a good Sensei should provide new knowledge and maybe enlightenment to stupid and boring
    warriors like me. I am stuck. But my attempted solution behaves exactly as requested, as far as I know,
    so I can't see where I got it wrong. Sure, I could give up and learn from the other warriors' solutions,
    But I don't want to give up, I want to solve this puzzle. And I am pretty sure I almost solved it.
    Please help me!

  • Default User Avatar

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

  • Custom User Avatar

    As @Chrono79 said, you're not supposed to scramble the digits. Otherwise, there's no way to obtain a unique solution.

  • Custom User Avatar

    You scramble numbers, not digits.

  • Loading more items...