Ad
  • Custom User Avatar

    Is there a way to see the random MiniStringFuck test that my program can't interpret? I don't really understand what I'm supposed to fix if I can't see the error in question.

  • Custom User Avatar

    Not a problem, hope you enjoyed :-)

  • Custom User Avatar

    Yes, I see where my mistake was. Thanks for your patience. I'm fairly dense most days and this just goes to show it. Passed all tests. Thank you.

  • Custom User Avatar

    Hi @john129er. Please refer to the descriptopn If you reach the end point before all your moves have gone, you should return Finish

    Hope this helps.

  • Custom User Avatar

    I know that much already. My code accounts for a random starting and ending location, not fixed locations. Here's the issue. For this maze:

    maze = [[1,1,1,1,1,1,1],
            [1,0,0,0,0,0,3],
            [1,0,1,0,1,0,1],
            [0,0,1,0,0,0,1],
            [1,0,1,0,1,0,1],
            [1,0,0,0,0,0,1],
            [1,2,1,0,1,0,1]]
    

    The answer to this line:

    Test.assert_equals(maze_runner(maze,["N","N","N","N","N","E","E","E","E","E","W","W"]), "Finish")
    

    should be "Lost", not "Finish". This is one of the test cases when I push the "RUN EXAMPLES" button. But because I can see the test case, I can fix your bug so my code will run correctly.

    However, when I hit the "ATTEMPT" button, I pass all the random tests (with random sized grids and random start/end locations). But there is one non-random test that I get this output from:

    Should return Finish - Expected: "Finish", instead got: "Lost"

    It's the seventh test case, just before the program is run through a bunch of random test cases.

    I'm wondering if, like in the test case I have above, this other test case should be fixed also. I can't see the test cases after pressing the "ATTEMPT" button so I can't verify that it really is an error. I just find it highly suspicious that I can pass every other test, including random tests with random start and end points, but I can't pass that one.

    I'm asking you to review all the test cases to make sure that you didn't accidently put the wrong outcome.

    Does that make sense?

  • Custom User Avatar

    The test before it Test.expect(mazeRunner(maze,["N","N","N","N","N","N","N","N","N","S","S","S","S","S","S","S","S","S"])=="Lost", "Should return Lost") is expecting "Lost". You're not mixing it up with that are you?

  • Custom User Avatar

    Hi @john129er. Sorry for the confusion, I've updated the description to make it more clear. The start and the finish positions will change for the final tests.

  • Custom User Avatar

    Hi @OscarAlvarez, I've checked the Javascript tests and that particular test is Test.expect(mazeRunner(maze,["N","E","E"])=="Dead", "Should return Dead") maybe I have the expected and actual the wrong way around. Please check your code to make sure it's not outputing "Lost".

  • Custom User Avatar

    For Ruby, I'm passing every single random test and all but one test case. For the last test case (non-random) I get:

    Should return Finish - Expected: "Finish", instead got: "Lost"

    Are you sure this isn't a typo?

    I noticed on the first round of test cases, the third test case should be "Lost", but it instead wants "Finish".

    Test.assert_equals(maze_runner(maze,["N","N","N","N","N","E","E","E","E","E","W","W"]), "Finish")

    But that's impossible for it to be 'Finish' when the finish line is on the very 'east' side of the maze! Please correct both the sample test case and the final test case when clicking submit.