HELP: Why O(n*1e5) doesn't give TLE

Revision en2, by HuTao_Oya_OyaOya, 2024-07-22 20:18:05
Problem Statement
Optimal Code

Link to the problem on GFG

Doubt: Can anyone explain to me how this code is working practically while theoretically O(1e4*1e5) should give TLE.

Is there any mathematically reason ?

Thanks for your time.

Tags thanks, for, your, time

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English HuTao_Oya_OyaOya 2024-07-22 20:18:05 111 Tiny change: '\n<spoiler s' -> '<spoiler s'
en1 English HuTao_Oya_OyaOya 2024-07-22 20:16:52 1440 Initial revision (published)