Two submissions with same Complexity , one gets TLE and other AC

Revision en1, by Saksham_Sahgal, 2022-02-15 09:15:16

i recently encountered a problem — 1208B - Уникальность

I have use a simple Binary search approach for that problem

I have 2 submissions , both are using Binary search and both have same worst case time complexity of O(N^2 log^2(N)) but one gives TLE and the other gets AC

AC submission — 146479295

TLE Submission — 146333083

can anyone tell me why this is happening?

Tags binary search, complexity, greedy

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English Saksham_Sahgal 2022-02-15 09:15:16 490 Initial revision (published)