What is multiple inheritance? Give Example
Answer Posted / hemanth
When class is derived from more than one base class, it is
called as multiple inheritance.
Class a {
int b;
public:
void fun();
}
Class C {
int d;
public:
void fun();
}
Class d :public a, public c {
int x;
void fun1();
}
----------
Here class d inherits class a and c, hence multiple inheritance.
Is This Answer Correct ? | 33 Yes | 0 No |
Post New Answer View All Answers
What is interface in oop?
Can bst contain duplicates?
What are two types of polymorphism?
What are the 5 oop principles?
What is difference between oop and pop?
can inline function declare in private part of class?
What is polymorphism in oops?
How to hide the base class functionality in Inheritance?
How many human genes are polymorphic?
what is the sylabus for priliminaries?
IS IT NECESSARY TO INITIALIZE VARIABLE? WHAT IF THE INSTANCE VARIABLE IS DECLARED final ? IS IT NECESSARY TO INITIALIZE THE final VARIABLE AT THE TIME OF THEIR DECLARATION?
What is polymorphism what is it for and how is it used?
Why is object oriented programming so hard?
Why do we need polymorphism in c#?
How to use CMutex, CSemaphore in VC++ MFC