In Python you can trade time-complexity for an increase in the memory usage of a Python script. For example, the factorial function is defined recursively f(5) = 5! = 5 * 4 * 3 * 2 * 1, where 1 is the base-case. But, what happens if we remember what 4! is equal to, by definition 5! is simply 5 * memo{4}