Hacker News new | ask | show | jobs
by firic 2817 days ago
Why is python 2.7 faster than 3? I thought one of the big reasons to switch to 3 was because of performance
2 comments

Where did you hear that? 3 hasn’t even been competitive vs 2 until very recently.

Reasons for the switch have always been better Unicode handling and not being left behind as the community matches on (and soon lack of security updates to 2).

Something to do with python 3 using long† integer as the default int, which can be arbitrarily long, so it may have slower arithmetics.

† not to be confused with the typical C long int type.