tirupati's blog

By tirupati, history, 11 years ago, In English

I was solving this problem today and I get a time limit exceeded verdict even though the time limit specified is 5s and the solution is O(n) and given bounds of n is 1<=n<=10^6. The problem can be found here and solution here.

Thank You

PS: Is there a problem with the judge?

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
11 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Try fast cin, cout.