Help needed in figuring out a TLE issue

Revision en1, by 100mil, 2022-01-09 13:04:49

I was solving this questions:https://codeforces.me/contest/1334/problem/C My solution:https://codeforces.me/contest/1334/submission/141932259

Could someone tell me why is this exceeding the time limit even though it is a O(n) solution?

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English 100mil 2022-01-09 13:04:49 280 Initial revision (published)