Glossary: Algorithms Beyond the Basics in C++
Optimal substructure
A feature where the best answer to the big problem is built from best answers to smaller ones, like `ways(n)` from `ways(n - 1)` and `ways(n - 2)`.
Glossary: Algorithms Beyond the Basics in C++
A feature where the best answer to the big problem is built from best answers to smaller ones, like `ways(n)` from `ways(n - 1)` and `ways(n - 2)`.