idonthatephy's blog

By idonthatephy, history, 2 years ago, In English

1426C - Increase and Copy this is the problem and below is the link to my code- https://codeforces.com/problemset/submission/1426/146922562 can anyone explain why I am getting TLE in test case 3? is it because of the timecomplexity O(sqrt(n)logn) or something else?

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

»
2 years ago, # |
  Vote: I like it +5 Vote: I do not like it

Yep, you're right. The time complexity is: O(T * sqrt(N) * log(N)), which leads to TLE.