Runtime Polymorphism
Runtime polymorphism is being able to assign different meanings to same
function at runtime.
It is also called Dynamic binding.
It is not default in C++ so it is achieved by –
1. Inheritance
2. Base class pointer
3. Virtual functions
1) Inheritance
Output –
2) Base class pointer
Output –
3) Virtual functions
Output –