Getting TLE for using upper_bound in BOX FITTING.

Правка en1, от im_mortal79, 2021-03-30 04:06:44

In the problem B of recent codeforces contest. I am using function upper_bound whose complexity is logn,but is still getting TLE see this 111426754 but after some minute changes in the code it got accepted see this 111426808 Now,I am not able to understand what is the difference in above codes. Please help me undestand.

Thanks in advance.

Теги #binary search, upper_bound, #multiset

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский im_mortal79 2021-03-30 04:06:44 422 Initial revision (published)