You are viewing a single comment's thread from:

RE: Python Tricks #7 - True and False are slow

in #programming7 years ago

Interesting.

I've just tried it out on Python 3.7.3. Most of the time test_1 is coming in at around 3.9xx and test_true is around 4.0xx with about a tenth of a second difference. A few times though, the timings flipped round and test_true was marginally faster.

When it's not almost 11pm I might have a fiddle and see if I can run them side by side and produce better results.

Sort:  

Thanks for the comment! :)

Posted using Partiko Android

Coin Marketplace

STEEM 0.04
TRX 0.33
JST 0.104
BTC 65181.08
ETH 1958.92
USDT 1.00
SBD 0.37