Simple Shopping Cart Write a program in python which, when run, asks a person for the quantity
Question:
Simple Shopping Cart
Write a program in python which, when run, asks a person for the quantity of oranges, apples, and bananas. It will then print out the quantities, a subtotal, a tax, and a total. The prices are fixed (apples - $1, oranges - $2, bananas - $3) and the tax is 10%.
An example interaction is shown below. The bold is where the user entered input and will not appear in your work.
Welcome to the Fruit Shop!
Please enter number of oranges: 3
Please enter number of apples: 2
Please enter number of bananas: 0
You ordered the following:
3 oranges at $1 each for a line total of $3.00
2 apples at $2 each for a line total of $4.00
0 bananas for $3 each for a line total of $0.00
Your subtotal is $7.00
Your tax is $0.70
Your order total is $7.70
For full credit, pay attention to variable datatypes and how items are displayed. Note that you will have to research how to format numbers to two decimal places. There are multiple ways to do this, please make sure you are using one of the Python3 methods.
Macroeconomics Principles and Applications
ISBN: 978-1133265238
5th edition
Authors: Robert e. hall, marc Lieberman