Ad
  • Custom User Avatar

    Though you have solved it, but I would like to suggest you consider console.log as your best friend and watch out for edge cases by re-reading the description several times. Kudos ^^

  • Custom User Avatar

    I got 101 passed test cases and only failed 3, I have confirmed that my logic is correct. It's impossible to know why those 3 test cases failed without providing the input walk array for the respective test cases.

  • Custom User Avatar

    In JavaScript console.log(array) can be used for this purpose. I don't know about other languages

  • Default User Avatar

    try putting the rooks on a (possibly virtual) chessboard for a small n (2, 3 or 4) and see how you would count the positions if you were to do it manually. you should be able to notice how the position of one rook determines that of the rook on the next rank or file

  • Custom User Avatar

    how does checking the arrays truthy value not meet the condition if the arr has a length greater than 1?

  • Custom User Avatar

    For the life of me I could not figure out a solution yet alone an elegant one, is anyone able to give me hints/tips? I don't think this is a 7kyu kata, I might be wrong though.

  • Custom User Avatar

    This Kata would benefit greatly with an example of the failed test case, instead of the expected equal alone. The basic test case is not enough for this Kata.