Блог пользователя education420

Автор education420, история, 5 лет назад, По-английски

I have a query related to the time complexity of the code.

Question: https://codeforces.me/problemset/problem/1265/B

My First Solution which was giving me timeout at 6th testcase: https://codeforces.me/contest/1265/submission/67753420

My Second Solution which got accepted: https://codeforces.me/contest/1265/submission/67753486

(Actually this is editorial code, I have copy pasted it).

Can please some one let me know why my first solution is giving me TLE and the second solution is getting accepted.

Merry Christmas.

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится