107k views
3 votes
Write a program that will ask the user to enter the amount of a purchase. The program should then compute the state and county sales tax. Assume the state sales tax is 5 percent and the county sales tax is 2.5 percent.in python

User Ima
by
7.4k points

1 Answer

4 votes

Answer:

This program first prompts the user to enter the amount of the purchase. It then defines the state and county sales tax rates as constants. It calculates the state and county sales tax amounts by multiplying the purchase amount by the appropriate tax rate. Finally, it calculates the total sales tax by adding the state and county sales tax amounts together, and prints the results.

Write a program that will ask the user to enter the amount of a purchase. The program-example-1
User David Pugh
by
7.2k points