Problem

Create a RestaurantMeal class that holds the name and price of a food item served by a res...

Create a RestaurantMeal class that holds the name and price of a food item served by a restaurant. Its constructor requires arguments for each field. Create a HotelService class that holds the name of the service, the service fee, and the room number to which the service was supplied. Its constructor also requires arguments for each field. Create a RoomServiceMeal class that inherits from both RestaurantMeal and HotelService. Whenever you create a RoomServiceMeal object, the constructor assigns the string “room service” to the name of the service field, and $4.00 is assigned to the service fee inherited from HotelService. Include a RoomServiceMeal function that displays all of the fields in a RoomServiceMeal by calling display functions from the two parent classes. Additionally, the display function should display the total of the meals plus the room service fee. In a main()function, instantiate a RoomServiceMeal object that inherits from both classes. For example, a “steak dinner” costing $19.99 is a “room service” provided to room 1202 for a $4.00 fee. Save the file as RoomService.cpp.

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT