Runtime error in the rat chases cheese problem


Please help me correct this

@prerna_gupta31 check if i or j becomes negative in case you pass i-1 or j-1,and check for left path too.

https://ide.codingblocks.com/s/148392?_ga=2.71435795.1265336461.1599648127-100718338.1597480284 I found this code from the discussion forum and I have understood this as well, but this also is not passing 1 test case