Question: Develop an object-oriented model and then write a C++ program as explained below. You will be using classes and objects, and appropriate member functions, constructors,

Develop an object-oriented model and then write a C++ program as explained below. You will be using classes and objects, and appropriate member functions, constructors, destructor, etc. to handle the tasks outlined below. You will divide up your H5 code into multiple-module program as discussed in class. Develop a C++ program that declares a base class Computer and will contain the following data member in the private access region: Manufacturer - PC manufacturer Model - PC Model Processor - Processor Type and Speed Model Year - Year Manufactured Weight - Shipping Weight There are two classes derived from the base class Computer. One class is Desktop and the other class is Laptop. The class Desktop adds the following data members in the private access regions region as shown below. Registration Number - PC Registration Number Serial Number - PC Serial Number Owner - PC Owner The class Laptop adds the following data members in the private access regions region as shown below. Screen Size - in inches Hard Drive Size - in GB or TB Color Options - case color The third class is named PC and will contain objects of the other two classes as its members ( declared in the private access region). This class is an example of has a relationship. You will declare and define all member functions for all three classes as needed, including constructors and destructors. Declare two objects of the class Desktop. Initialize the first object using the default constructor. Initialize the second object using overloaded constructor. The data needed for the second object is obtained from the keyboard before the object is constructed. Follow the same procedure for the Laptop objects. Once all objects are created, you print the information for each of the four objects. You can define your own method(s) to accomplish these tasks (you have many options)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
