Skip to content

Glossary: C++ Beyond the Basics

Polymorphism

One piece of code serving many types, chosen at run time. A function taking `const Discount&` works for any kind of discount.

Where the book teaches it

Related terms

Dynamic dispatchVirtual function