Answered step by step
Verified Expert Solution
Question
1 Approved Answer
C++ Ex 1. Driver Class Implement Class driver as described in the UML diagram above. Ex 2. Order Class Implement Class Order as described in
C++
Ex 1. Driver Class Implement Class driver as described in the UML diagram above. Ex 2. Order Class Implement Class Order as described in the UML diagram above. Notice that, driver, customer, date protected and not private in this class. Ex 3. RestaurantOrder class Implement class RestaurantOrder, which inherits from class order . Note the following: 1- Parameterized constructor that receives all data members including data members in the base class. 2- print details () of the base class should be overridden to print the additional information about the restaurant name and meal name . Ex 3. MertOrder class Implement class MertOrder, which inherits from class order . Note the following: 1- Parameterized constructor that receives all data members including data members in the base class. 2- In calculate total (), you have to sum all the prices of the items and store the result in price. 3- print details () of the base class should be overridden to print the additional information about the items and items price. 4- There are three things that must be defined inside the MertOrder class that are not explicitly requested and must exist. What are they? Define two of them within the class. Ex 4. Driver Implement a driver program to test your code. 1- Create an object of type Date, Customer, Driver 2- create an object of type Order using created in 1. 3- create an object of type RestaurantOrder and MertOrder . 4- set the price of RestaurantOrder object to 50. 5- print the detail of order object and MertOrder object. 6- if you use private or protected inheritance, which part of your code is going to be wrong? why ? Answer this part as a comment in your mainStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started