When should you employ multiple inheritance?, C/C++ Programming

Q: When should you employ multiple inheritance?

A:There  are  three  acceptable  answers:-  "Rarely," "Never," and  "while  the  problem  domain cannot be modeled accurately any other way." Presume an Asset class, developing class, Vehicle class, and CompanyCar class. All of the company cars are vehicles. Some of the company cars are assets since the organizations own them. Others may be leased. Not all of the assets are vehicles. Money accounts are assets. Real estate storing are assets. Some of the real estate holdings are buildings. Not every building is assets.  Ad infinitum.  While you diagram these relationships, it becomes clear that multiple inheritances are a probable and intuitive way to model this common problem domain. The applicant must understand, though, that multiple inheritance, such as a chainsaw, is a useful tool which has its perils, needs respect, and is best ignored except while nothing else will do.

 

Posted Date: 3/16/2013 2:51:54 AM | Location : United States







Related Discussions:- When should you employ multiple inheritance?, Assignment Help, Ask Question on When should you employ multiple inheritance?, Get Answer, Expert's Help, When should you employ multiple inheritance? Discussions

Write discussion on When should you employ multiple inheritance?
Your posts are moderated
Related Questions
What are the various types of control structures in programming? - Primarily there are 3 types of control structures in programming: Sequence, Selection and Repetition. - Se

In this lab, please complete a given program to perform the following tasks: 1. Allocate a 10 by 5 2D byte array dynamically. The way of allocation must be consistent with pag

How do you declare an integer variable? Explain with an example.

write a program that counts the number of occurrences of the string in the n-th Padovan string P(n)   program in java // aakash , suraj , prem sasi kumar kamaraj college

How do you know that your class requires a virtual destructor? A: If at least your class has one virtual function, you must make a destructor for this class virtual. It will let

By pressing ‘6’ (i.e. key’6’ one time) on the keypad, the mobile shows ‘m’ on display screen in write text message area

I have to add virtual void calculatePay and virtual void displayEmployee. How to I implement that in Salaried and Hourly Employee?

how can i print any english work using star .?

write a C rpogram that can display the transpose form of a ciphertext matrix.Prompt users to provide row and coloumn number of matrix.Then user will input plaintext and the program

This programming assignment is for use in the LINUX/UNIX environment!! Introduction: System administration often requires custom written programs and tools. One problem a s