Difference in Execution Time between C and C++ Solution

Правка en2, от akash19jain, 2019-10-17 09:42:05

I submitted a solution in C and was pretty sure that it would pass the given Time Limit, but I received a TLE and was surprised. Next I submitted the exact same solution in C++ and it passes in 0.6 Sec while the one in C couldn’t pass in even 5 seconds. Can anyone tell me as to why this happened? Link to C solution: https://codeforces.me/contest/282/submission/62757397 Link to C++ solution: https://codeforces.me/contest/282/submission/62757469

Теги #tle, #doubt

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский akash19jain 2019-10-17 09:42:05 2
en1 Английский akash19jain 2019-10-17 09:41:44 511 Initial revision (published)