C++ program to implement the use of Virtual functions and Pure Virtual functions:
Classes that contain at least one pure virtual function is called Abstract classes. The pure virtual functions must be defined in the derived classes, or else they also become Abstract. Abstract classes cannot be used to create objects. But can be used to create a pointer to that class type. Virtual functions provide dynamic binding to the functions defined in the derived classes.
Binding: Connections between the function call statement and the function definition.
Dynamic Binding: Binding that happens during the runtime.
Static Binding: Binding that happens during the compile time.
S.Ravi Kiran, Competitive Sport Programmer.