What do you mean by pure virtual functions?
A pure virtual member function is a member function that the base class forces derived classes to
provide. Normally these member functions have no implementation. Pure virtual functions are
equated to zero.
class Shape { public: virtual void draw() = 0; };
A pure virtual member function is a member function that the base class forces derived classes to
provide. Normally these member functions have no implementation. Pure virtual functions are
equated to zero.
class Shape { public: virtual void draw() = 0; };
Very good - thanks! Detail explanation here also:
ReplyDeletehttp://www.programmerinterview.com/index.php/c-cplusplus/pure-virtual-function/