Why is my answer wrong?

https://www.codechef.com/viewsolution/23719567