-2

This time we would like the user to enter the following details for 3 items: name, cost price and quantity. Your program should the print out a receipt including a tax amount of 11.75% on the subtotal of all the three items entered. The receipt should be formatted in columns with 30 characters for the name, 10 characters for the quantity, 10 characters for the price, and 10 characters for the total.
Sample run 1:

Item Quantity Price Total
Lollipops 10 0.50 5.00
Sweets 4 1.45 5.80
Chocolate bar 20 0.75 15.00
Subtotal 25.80
11.75% sales tax 3.03
Total 28.83

Votes + Comments
Lazy
2
Contributors
1
Reply
18
Views
5 Months
Discussion Span
Last Post by JamesCherrill
1

@Elifas.
Did you bother to spend even a few moments reading the "Read this before posting a question" at the top of the page?

We do not waste time helping people who are so lazy that all they can do is post their homework task verbatim and wait for someone else to do something.

We help a lot pf people here, and we will help you, but only of you show some effort first.

Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.