And what about this? def fib(n, cache={0:0, 1:1}): if not n in cache: cache[n] = fib(n-2) + fib(n-1) return cache[n] Gregor > >