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

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

Today, I submitted a Python3 program to the "Going Home" Problem in Round 707. My program passed all pretests, but unfortunately did timeout when tested. After the contest I looked at some other Python3 solutions, and they looked very similar to my solution. I changed a few minor things, every version was accepted. Eventually I decided to submit my original contest solution again. To my surprise it passed as well! Why now and not in the contest?!?

Lessons learned:

  1. Even if pretests are passed, it's probably safer to submit with PyPy instead of Python.
  2. When your time is close to the time limit, you may be lucky, or you may be unlucky.
  • Проголосовать: нравится
  • +3
  • Проголосовать: не нравится

»
6 лет назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Moodymann (previous revision, new revision, compare).

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

My experience is that since Python3.9 is available on Codeforces, it's faster than PyPy3.