Could anyone tell which testcase is being failed by my code for this question (INFERNO)

I want to know a testcase where my code is going wrong but I cant see it ,
Question code is INFERNO from STARTERS 37 . And also what is the error and how to rectify it .

The link to my solution is Solution: 64211903 | CodeChef

1 2

Expected 2, got 1.