Giving TLE in Chef and Mover (August Long 2017)?

I have been trying to solve the Chef and Mover problem and getting time limit exceeded, when I submit the code, I ran my code with the inputs given for the problem in code chef IDE and it ran in 0.4 sec, against what more inputs should I check my code to know why I m getting TLE on submitting.

Asking for help during contest isnt allowed dear.

oh alright, my bad.