Using C++ to create the following:
Create a class namedVehicle. The class has the following five member variables:
Include set (mutator) and get (accessor) functions for each field except the total price field. The set function prompt the user for values for each field. This class also needs a function named computePrice() to compute the total price (quantity times unit price + salesTax) and a function to display the field values. [Note: Sale tax is 10%, sale tax = Unit price * saleTax)
Create a subclass named VehicleOrder that overrides computePrice() function by adding a shipping and handling charge of $12.00.
Write an application named UseVehicle that instantiates an object of each of these classes.
Prompt the user for data for the Vehicle object, and display the results, then prompt the user for data for the VehicleOrder object, and display the results.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here