> If you're using Python 3.2+, then functools.lru_cache probably > ... And if you're on 2.X, you can grab lru_cache from http://code.activestate.com/recipes/498245-lru-and-lfu-cache-decorators/