AC versus TLE



Dear admin,

Why is it the case that the same code gets accepted on one submission and is adjudged TLE on another submission??

Of course, I had tuned some parameters in my program, so that it will finish execution, just in time.

I know that different executions will take different times to execute (with minor difference between them). Is it just because of this that one submission got adjudged TLE? Or can it also be because of other server parameters, like the load at that time on the judge?


Yes, I also have had the same sort of experience, In the problem chmod the difference b/w my AC code and TLE code is like 2-3 operators.


In DELNMS, I got a solution accepted. I added a few extra lines of code, but commented all of them out. So, effectively, it is exactly the same code.

Submitted this again, only to get TLE.


sth like this also happened to me today. replaced an indexed for-loop by an iterator for-loop in some code, and switched my TLE to AC. sometimes, it’s just a matter of milliseconds, it seems… :slight_smile: