Snake and Ladder (hacker blocks)


Code running fine on sample test case but getting WA in test case 1 and AC in test case 2. What corner case am I missing?

@pratyush34
Condition in line no. 31 is wrong it should be if(dist[nbr]>(dist[node]+1))