What is multiple inheritance? Give Example

Answer Posted / sadikhasan,meta

Multiple inheritance means duplicate copy of base class is
derive into child class. which explain by following example.
class A
{
}

class B: public A
{
}

class C:public A
{
}

class D:public B,public C //duplicate data
{
}

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is balance factor?

580


What is the use of oops?

616


What is multilevel inheritance in oop?

553


can inline function declare in private part of class?

3653


What is polymorphism in oop example?

511






What is oops with example?

560


Following are the class specifications: class {int a}; class {int b}; Using friend funtion,calculate the max of two objects and display it.

2002


What is encapsulation with real life example?

566


#include #include #include #include void insert(char *items, int count); int main(void) { char s[255]; printf("Enter a string:"); gets(s); insert(s, strlen(s)); printf("The sorted string is: %s.\n", s); getch(); return 0; } void insert(char *items, int count) { register int a, b; char t; for(a=1; a < count; ++a) { t = items[a]; for(b=a-1; (b >= 0) && (t < items[b]); b--) items[b+1] = items[b]; items[b+1] = t; } } design an algorithm for Insertion Sort

2157


Question: Write a program that prints a paycheck. Ask the program user for the name of the employee, the hourly rate, and the number of hours worked. If the number of hours exceeds 40, the employee is paid “time and a half”, that is, 150 percent of the hourly rate on the hours exceeding 40. Be sure to use stepwi se refine ment and break your solution into several functions. Use the int_name function to print the dollar amount of the check.

689


What is a class in oop?

595


c++ program to swap the objects of two different classes

1756


Can we create object of interface?

601


What does and I oop mean in text?

616


They started with the brief introduction followed by few basic C++ questions on polumorphism, inheritance and then virtual functions. What is polymorphims? How you will access polymorphic functions in C? How virtual function mechanism works?

1403