Review Questions
1: | What does a derived class inherit from a base class? |
2: | What doesn't a derived class inherit from a base class? |
3: | Suppose the return type for the baseDMA::operator=() function were defined as void instead of baseDMA &. What effect, if any, would that have? What if the return type were baseDMA instead of baseDMA &? |
4: | In what order are class constructors and class destructors called when a derived class object is created and deleted? |
5: | If a derived class doesn't add any data members to the base class, does the derived class require constructors? |
6: | Suppose a base class and a derived class both define a method of the same name and a derived class object invokes the method. What method is called? |
7: | When should a derived class define an ... |
Get C++ Primer Plus, Fourth Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.