Write a function that displays the menu prompts user for a


The language is c++.

Product Cost per Ounce Plain Coffee $0.13
Latte $0.23
Macchiato $0.25
Frappuccino $0.28

Determines the number of each type of cup to reduce the number of Shot cups used.

Add functionality to your program so that a Regular (8 oz) cup will be used instead of multiple Shot (1 oz) cups if the number of Shot cups needed exceeds 3.

For this project, your list MUST include the following:
- a function that displays the menu, prompts user for a choice, validates the choice and returns a valid option.
- a function that accepts a number of ounces and displays the number of Venti, Grande, Regular and Shot cups needed
- a function that accepts a type of coffee and a number of ounces ordered and returns the base cost of the coffee
- a function that ONLY accepts a name, type of coffee and number of ounces and displays the coffee bill.

Content and format of bill should match the Sample Output

Make sure your program uses the values returned from your functions. Any functions that need input to perform a task will have to accept parameters. Global variables are prohibited.

1. Add functionality to calculate the total cost of all the coffee bills in the text file. Display the total cost after displaying the individual coffee bills. Make sure your program will correctly calculate the total cost. The format should match the one in the Sample Output.

2. Write a function that displays the menu, prompts user for a choice, validates the choice and returns a valid option

3. Write a function that accepts a number of ounces and displays the number of Venti, Grande, Regular and Shot cups needed formatted as shown in the Sample Output.

4. Write a function that accepts a type of coffee and a number of ounces and returns the base cost (sales tax not added) of the coffee.

5. Write a function that only accepts a name, a type of coffee and a number of ounces and displays the coffee bill.

Solution Preview :

Prepared by a verified Expert
C/C++ Programming: Write a function that displays the menu prompts user for a
Reference No:- TGS02608278

Now Priced at $20 (50% Discount)

Recommended (96%)

Rated (4.8/5)