ECE39595-Homework 4 Solved

30.00 $

Category:
Click Category Button to View Your Next Assignment | Homework

You'll get a download link with a: zip solution files instantly, after Payment

Securely Powered by: Secure Checkout

Description

Rate this product

Part A:

Using the code in the directory PartA, convert Vehicle to be an abstract class. Make all functions that are overridden with different functionality in HondaFit and FordF350 pure virtual functions. Make functions that have the same functionality in HondaFit and FordF350 concrete functions with implementation.

Make sure the program compiles and runs with the same output as in HW2.

Part B:

In the PartB directory there is a Makefile and some C++ code that doesn’t compile.  This homework will have three steps, which you will perform by editing the code in PartB.  You will turn in only the final code.

Step 1: get the program to compile

Step 2: (you may end up doing some of these as part of Step 1, that’s ok)

  1. Modify the Address constructor so that its body (what is between the “{“ and “}”) is empty and use initializer lists to do all initialization.
  2. Modify the Person constructor so that the body only contains the initialization of dateOfBirth, but all initializations are done.
  3. Modify the Employee constructor so that its body is empty but all initializations are done.
  4. Enable all functions to be callable as virtual functions.
  5. Any other changes you need to make to get the desired output (see below).

Step 3: Convert the program to use no pointers and no new operations, i.e. use object variables whenever possible

The output of Part B when finished will look like:

add1:

1281 Gruene Rd

Greune

TX

78130  add2:

801 Bldg

Yorktown Heights

NY

10598

 

Employee1: Employee, Jerry Jeff Walker, 78130

Employee2: Employee, Fran Allen, 10598

  • HW4Assignment-8rzmke.zip