Question: What mistake prevents the following class declaration from fnctioning properly as an abstract elass? class Shape public: virtual double print ) const; double area()
What mistake prevents the following class declaration from fnctioning properly as an abstract elass? class Shape public: virtual double print ) const; double area() const { return base * height; } private: double base; double height; }; Select one: O a. the virtual function is defined const O b.it does not have a constructor O. There is a non-virtual function O d. There are no pure virtual functions
Step by Step Solution
3.44 Rating (157 Votes )
There are 3 Steps involved in it
Answer a A virtual function is a member function that you expect to be redefined in derived classes ... View full answer
Get step-by-step solutions from verified subject matter experts
