# Dynamic Programming

*noun*

say it: **“dy-NAM-ik PROH-gram-ing”** **/daɪˈnæmɪk ˈproʊɡræmɪŋ/**

Solving a problem by working out the answers to its smaller versions first, from the smallest up, and keeping them in a table.

## What is **dynamic programming**?

**Dynamic programming** solves a problem by working out the answers to its smaller versions first, from the smallest up, and keeping them in a table, so no answer is ever worked out twice. Counting the ways to climb stairs 1 or 2 at a time fills the table 1, 1, 2, 3, 5, 8… with one loop.

## In a sentence

- “I used **dynamic programming** to fill a table of staircase answers from 0 stairs up to 50 with one loop.”

Level: Freelancer · [More Data Structures terms at this level](https://www.ask-codey.com/glossary?category=data-structures&level=4)

Updated: November 9, 2026

Source: https://www.ask-codey.com/glossary/dynamic-programming
