Question: using C++ 4. You are to write a program that can be used in an Caf for displaying the menu using a function called DisplayMenu

using C++ 4. You are to write a program that can be used in an Caf for displaying the menu using a function called DisplayMenu which will display the prices of following items: (this is just a sample exercise, but you should be able to easily add more items into the menu). Regular Coffee: $1.99 Cappuccino: $3.99 Donut: $0.69 Danish: $1.29 Muffin: $0.99 From main, first call this function to display the menu, then main will ask user what they like to order and how many quantities of each item: main can store these data as item1, item2, item3, item4, item5 (the number of quantities for each item). Then main passes these numbers to another function Cost to compute the total cost of all the items customer will buy. The formula for cost will be: totalCost = item1 * 1.99 + item2 * 3.99 + so on. The function Cost should return this total cost. So, there are two functions: DisplayMenu and Cost. The Cost function has five parameters: item1, item2, item3, item4, item5, but DisplayMenu function has no parameters, and it does not return any value, simply displays the menu as shown above.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!