- One of the goals of Object Oriented Programming is genericity.
- Ideally, generic programs can be written once, compiled once
and used for different data types.
- C++ achieves genericity two ways:
- Using virtual functions and derived classes
to achieve polymorphism.
- Using templates to mimic polymorphism.
Templated classes must be re-compiled for each data type. Some do not
consider this OOP.