Bryce H.

asked • 01/23/23

to write a code block on python that will answer the below

Write a simple "shopping cart" program that asks the user for a series of product prices. Compute sales tax (7%) on each price and print out the new price to the user. Next, ask the user if they want to enter another price - if they do, repeat the process. If not, end the program.

 

Sample:

Enter an item price: 1.00

Tax on this item is 0.07 ; total price: 1.07

Enter another price? (yes or no): yes

Enter an item price: 2.00

Tax on this item is 0.14 ; total price: 2.14

Enter another price? (yes or no): yes

Enter an item price: 3.00

Tax on this item is 0.21 ; total price: 3.21

Enter another price? (yes or no): no


1 Expert Answer

By:

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.