Пожалуйста, подпишитесь на официальный канал Codeforces в Telegram по ссылке https://t.me/codeforces_official. ×

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

Автор narendra_chiku, история, 2 года назад, По-английски

Hello Codeforces!

During Educational Codeforces Round 130 (rated for Div 2) contest, I submitted my solution for Problem C 1697C - awoo's Favorite Problem in GNU G++17 7.3.0 and I got TLE on testcase 10 as verdict and after contest when I submitted the same solution in GNU G++17 9.2.0(64 bit, winlibs), what I saw, the code got ACCEPTED. This whole thing burnt my mind and that's why I am writing this blog.

Here's a proof for the same I mentioned.
For solution 160374839, got TLE as verdict.
For this solution 160450643, got ACCEPTED.

MikeMirzayanov please looks into it and explain it properly and also if possible accept my solution.

Guys please upvote if u are agree with this.

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

»
2 года назад, # |
  Проголосовать: нравится +2 Проголосовать: не нравится

Codeforces must keep a better compiler (GNU G++17 9.2.0) only, so that no one faces similar issues in upcoming contests.

»
2 года назад, # |
Rev. 2   Проголосовать: нравится +11 Проголосовать: не нравится

GNU G++17 7.3.0 is 32 bit and 64 bit long long datatype is slow in it comparable to int .
I just change the the following line: #define ll long long int into #define ll int, and your code get accepted in c++17.

when you use 64 bit in c++ it's preferable to use c++ 64 bit and also for python programmers pypy64 is very powerful than pypy3 32 bit.