On 23.04.2018 19:31, Tim Peters wrote: > Surely you're joking. This is math.gcd(), which is expensive for > multi-thousand bit integers, and the interpreter knows nothing about > it. Adding a cache of _any_ kind (LRU or otherwise) would make it > even slower. Alright, if that problem is just about performance, then there must be a better way to resolve it rather than inventing a new syntax. Btw. storing the result in a local var is also a cache IMHO. And if gcd is immutable, I think Python can do a great job here of optimizing. Anyway, your example is the best one I've seen so far.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4