Exam Day : TLE

I don’t understand why this simple code is giving TLE.
Any helps would be appreciated.

Even if there is some minor(or major :P) fault in the logic, it should at max give a WA I suppose?
Thanks! :slight_smile:

Solutions are not public. Put it on ideone.

Can i get the practice link for this problem.

Put strlen() out of the loop. It is every time calculating the length making the solution O(n^2)

Hi,

The solutions are now public and the problems have been moved to the practice section so that you can understand the bugs in your codes.

Problem 1 - Exam Day

Problem 2 - Sad Boys

Problem 3 - Mario

Problem 4 - Quick-Math Quiz

  • Kshitij :slight_smile:

1 Like

Oops,totally forgot it! Here you go.