[Solved] ECE39595-Homework 4

$25

File Name: ECE39595-Homework_4.zip
File Size: 178.98 KB

SKU: [Solved] ECE39595-Homework 4 Category: Tag:
5/5 - (1 vote)

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 doesnt 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, thats 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

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] ECE39595-Homework 4
$25