Question: problem 1 is above here Write a program to determine the total cost for a set of purchases. The program should: use a while loop
problem 1 is above here
Write a program to determine the total cost for a set of purchases. The program should: use a while loop to prompt the user for each purchase's information, including for each item the number of items and the unit cost at the end of the while loop, get user input on whether there are more items after the while loop, calculate tax at 7.5% display the pre-tax cost, the amount of tax, and the total cost including tax Here is an example session: Item 1 Enter count of item 1: 2 Enter unit cost for item 1: 5.25 More items (y/n)? y Item 2 Enter count of item 2: 1 Enter unit cost for item 2: 10.50 More items (y/n)? n Enter sales tax rate (%): 7.5 Total cost (pre-tax): 21.00 Sales tax: 1.57 Total cost (with tax): 22.57 Activat Go to Set
Step by Step Solution
3.58 Rating (151 Votes )
There are 3 Steps involved in it
1 a... View full answer
Get step-by-step solutions from verified subject matter experts
