Dynamic programming tables

Dynamic programming is taught as a recurrence and understood as a table, and the gap between those two is where most people give up. Three things close it and all three are visual: which cells the current cell depends on, drawn as arrows; the order the table fills, and why the dependencies force it; and the traceback, since the table holds the cost but the answer is the path back through it. Most explanations stop at the number, which is the half that is easy.

8 algorithms

The same Fibonacci computation is drawn as a call tree in Recursion. Sorting and searching live in AlgoLab, traversal and shortest paths inGraph algorithms, and pattern matching in String matching.