With due respect to you ,please help me to understand this problem

Please help me to solve this question .

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