Rat in a maze problem

2 test cases wrong