0 votes
What is virtual function example?

2 Answers

+1 vote
Explain with an example. - A virtual function is a member function that is declared within a base class and redefined by a derived class. When a class containing virtual function is inherited, the derived class redefines the virtual function to suit its own needs. - Base class pointer can point to derived class object.
0 votes
VIRTUAL FUNCTION : C++ programming Concept