Skip to content

Glossary: Coding Interviews in JavaScript

Dynamic programming (DP)

Also written: dynamic programming, DP

Solving each overlapping subproblem once and saving its answer, either with a memo (top-down) or a table (bottom-up). It speeds up slow recursion like the fewest-bags example.

Where the book teaches it

Related terms

Overlapping subproblemsSubproblemMemoTop-downBottom-up