Question
Write a C++ code Develop a program working as a soda vending machine. The program should show the product menu with price and take user
Develop a program working as a soda vending machine. The program should show the product menu with price and take user input for product number, quantity and pay amount. The output should show the total sale price including tax and the change.
Planning - Program INPUT PROCESS OUTPUT
Input | Process | Output |
|
|
|
Code this program using the 5 functions indicated by the flowcharts. Use the tax rate as 6% (0.06). Be sure your code is structured (only one return in each function, no exit, or continue, or breakexcept in switch.)
SAMPLE OUTCOME
WORKING WITH FUNCTIONS
1. Coke $1.25
2. Pepsi $1.00
3. Water $2.00
4. Coffee $1.50
5. Exit Menu
Please enter the number of your choice from the menu 3
Please enter the number of this drink you want 2
Please enter the payment amount $10
The total amount of the purchase, including tax = $4.24
The amount of payment = $10
The amount of change returned = $5.76
Programmer(insert your name here)
Step 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