(Request) Update PyPy's Version on CF
Difference between en6 and en7, changed 259 character(s)
I've always liked using Python (PyPy) for solving problems in competitive programming. And most problems are very doable, even in Python. What I've found is that the most difficult problems to solve in Python are those requiring 64 bit integers.↵

The reason why 64 bit integers are problematic is because CF runs Windows, and PyPy only supports 32 bit on Windows. So whenever a problem involves integers that cannot fit inside of a signed 32 bit int, PyPy switches to big integers (which runs insanely slow, sometimes a factor of 20 times slower).↵

<spoiler summary="What I currently have to do to get around big integers">↵
### 1. Switching to floats↵
What I usually try is switching from using integers to floats. This works if all integers are $\leq 2^{52}$:↵

[submission:53441394] (Fat TLE and almost MLE) vs [submission:53456822] (AC by a mile)↵

### 2. Calculating `a * b % MOD`↵
Many problems on CF involve doing multiplication modulo $10^9 + 7$. This is super slow because of big integers. After a long time of trying around with different methods, I've found that [this](https://github.com/cheran-senthil/PyRival/blob/master/pyrival/misc/mod.py) is the best solution. Today I always use it whenever I do multiplication mod $10^9 + 7$. But sadly, while it is much faster than using big integers, it is still slow compared to doing `a * b % MOD` in 64 bit PyPy.↵

### 3. When all else fails↵
Another trick is to use a deprecated feature that only exists in PyPy2:↵

[submission:114602234] (Fat TLE) vs [submission:114611359] (AC by a mile)↵

A big warning here. Not only is this feature deprecated, but from my own personal experience using it means opening a can of worms. I will only use this as an absolute last resort.↵
</spoiler>↵

However with the latest PyPy version (version 7.3.4) PyPy has finally switched to 64 bit on Windows! So upgrading PyPy would mean no more problems with big integers. This would make PyPy far more usable and more beginner friendly. So if possible please update PyPy's version on CF to 7.3.4! [user:MikeMirzayanov,2021-04-29]↵

Edit: Reading [Results of 2020 [list some changes and improvements]](https://codeforces.com/blog/entry/88691) blog I realized that I should probably be tagging [user:geranazavr555,2021-05-02], [user:kuviman,2021-05-02] and [user:cannor147,2021-05-02] too.↵

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en7 English pajenegod 2021-05-02 15:49:11 259 Tiny change: 'nazavr555] and [use' -> 'nazavr555], [user:kuviman] and [use'
en6 English pajenegod 2021-04-29 21:58:13 9 Tiny change: '. Today I will always use this whenever ' -> '. Today I always use it whenever '
en5 English pajenegod 2021-04-29 21:46:08 0 (published)
en4 English pajenegod 2021-04-29 21:35:35 588 Tiny change: ' problems involve d' -> ' problems on CF involve d'
en3 English pajenegod 2021-04-29 21:16:23 51
en2 English pajenegod 2021-04-29 21:09:59 2
en1 English pajenegod 2021-04-29 21:08:12 1503 Initial revision (saved to drafts)