4. [5] In C++ private inheritance all the members of the base class are inherited as either private or protected members in the derived class. Explain how private inheritance can be used to implement a subtype relation, or explain why this is not possible (as the case might be).

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter11: Inheritance And Composition
Section: Chapter Questions
Problem 21SA
icon
Related questions
Question
4. [5] In C++ private inheritance all the members of the base class are inherited as either private
or protected members in the derived class. Explain how private inheritance can be used to
implement a subtype relation, or explain why this is not possible (as the case might be).
Transcribed Image Text:4. [5] In C++ private inheritance all the members of the base class are inherited as either private or protected members in the derived class. Explain how private inheritance can be used to implement a subtype relation, or explain why this is not possible (as the case might be).
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning