WA in FFC219G

Can anyone help me with the error in my code for Fall for Code 2.0 - FFC219G
Soln - https://www.codechef.com/viewsolution/26911655