1.

How many base classes can a single derived class have in C++?(a) 1(b) 2(c) 3(d) As many as requiredI had been asked this question in an international level competition.The above asked question is from Base Class in division Classes of Object Oriented Programming

Answer»

Correct option is (d) As many as required

To explain I WOULD say: This is because C++ allows multiple INHERITANCE. A DERIVED CLASS can have more than ONE base class and hence can derive all of their features.



Discussion

No Comment Found

Related InterviewSolutions