This one was kind of fun once I figured out what they were asking for. That seems to be the case for all of these codechef problems.