Time complexity vs Input Size

Правка en1, от kazuya, 2020-07-27 20:09:33

I was solving this problem 1202B - You Are Given a Decimal String... and I got some idea about it but the time complexity for my algorithm was O(10^8) and since time limit mentioned was 2 sec I didn't implement it and decided to look at the editorial, in which author mentioned this : But, it will work only in C++, since the language is fast and 2⋅10^8 basic operations are executed in less than 0.5 seconds. Can someone explain this? (as far as I know up to 10^6 operations can be done in 1 second, so for 2 seconds ~ 2*10^6, right ?).

Теги #running time

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский kazuya 2020-07-27 20:16:24 39
en1 Английский kazuya 2020-07-27 20:09:33 549 Initial revision (published)