by mattj · 14y ago · 0 comments
Memoization, however, is much more of a black-box. Very few compilers will handle the branching present in memoized function calls in the same way they'd handle a loop (which is also a branch, but a more predictable one).
That all being said, memoization is often simpler to reason about and great for infrequent computations.