The document discusses dynamic programming and amortized analysis. It reviews how dynamic tables use amortized analysis to achieve an overall cost of O(1) per insertion by occasionally doubling the table size and reinserting all elements. This results in a worst case cost of O(n) for a single insertion but averages to O(1) over many insertions. It also discusses using an accounting method with a $3 charge per insertion to pay for future table resizes, achieving an amortized cost of O(1) per operation. Finally, it introduces dynamic programming and uses the longest common subsequence problem to illustrate how it breaks problems into optimal subrecurring subproblems.