TLE showing for one test case

my solution got accepted on SPOJ but here it is giving TL for one test case.

Can you save your code on ide.codingblocks.com and send the link of the same.

link to the code has been posted