Ad
  • Custom User Avatar

    Haha, don't worry, I understood what's needed, I'll do that soon. :) Anyways, since my translation has been openeded for quite some time, I doubt the Kata owner is still active / willing to maintain this kata.

    Thanks for the pointers, though!

  • Custom User Avatar

    Hi there,

    Not really active anymore but definitely willing to fix this if this can help, what would be needed to be changed?

  • Custom User Avatar

    I changed the requirements to remove the stack from the expected return value so I'm flagging your suggestion as solved.
    Please let me know if you think of any other enhancements. :)

  • Custom User Avatar

    Hi,

    For the input data, I first thought of a multiline string encoding the map and the robot position altogether, which obviously will be more readable but will require warriors to transform the input to adequate data structures (or worse, some might want to try to deal directly with the map instead of using well-suited data structures). I felt this would be unecessary boilerplate code in solutions so I'm not satisfied with the idea either.
    Maybe a good alternative would be to provide a helper function to print the map and the robot in a more human-readable format (and include an example test case that demonstrate the feature). What do you think?

    For the random tests, what would be the goal of them? Avoid cheating? (I ask because I've already seen suggestions for random test on other Kata and I'm not sure of the point)
    Anyways, it is indeed possible to implement some with one of the following way:

    • Encoding a lot of puzzles and their solutions and randomly pick some of them
    • Writing a puzzle generator (which also generates a working program), maybe using some common base patterns tied together randomly, and call it a few times within the test suite.

    Both of the solutions will require quite some work but I promise I'll take some time to think about that. I prefer the generator since it would then be possible to provide the generator functions to warriors, which will provide value in the sense it can help understanding the game.

    Thanks for the feedbacks, I hope you enjoyed the Kata :)

  • Custom User Avatar

    Hi,

    Thanks for the feedback, it's my very first authored Kats and I definitely appreciate the valuable feedback.

    I think I will remove the stack requirement then since it actually seems to be painful to get it right and provide no value to the tests (in fact my original Ruby solution had the very same issue with my tests so I reversed the stack before returning too since the order imposed by the tests seemed more logical to me), it will also have the nice side effect to remove boilerplate from the tests and make it more readable.

    I hope you enjoyed the Kata despite this weird behaviour

  • Custom User Avatar

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

  • Custom User Avatar
  • Custom User Avatar

    This is my first translation, feel free to give some feedback! (also I'm still in the process of learning Elixir, so the solution might not be state-of-the-art Elixir code :) )