Question: Instructions To make a profit, a local store marks up the prices of its items by a certain percentage. Write a C + + program

Instructions
To make a profit, a local store marks up the prices of its items by a certain percentage.
Write a C++ program that reads:
The original price of the item sold
The percentage of the marked-up price
The sales tax rate.
The program then outputs:
The original price of the item
The percentage of the mark-up
The stores selling price of the item
The sales tax rate
The sales tax
The final price of the item.
(The final price of the item is the selling price plus the sales tax.)
Since your program handles currency, make sure to use a data type that can store decimals.
Task #01: Correct output calculated and displayed
Test Feedback:
Status: FAILED!
Check: 1
Test: Test case 1
Reason: Unable to find '['100','29.9','129.9','8.6','11.1714','141.071']' in the program's output.
Enter the original price of the item: Enter the percentage of the mark-up: Enter the sales tax rate (as a percentage): Original price of the item: $100.00
Percentage of the mark-up: 29.90%
Store's selling price of the item: $129.90
Sales tax rate: 8.60%
Sales tax: $11.17
Final price of the item: $141.07
.
Error : AssertionError - Unable to find a number close enough to 11.1714(+/-0.00) in the program's output.
Timestamp: 2024-01-1915:37:47.742306
Status: FAILED!
Check: 2
Test: Test case 2
Reason: Unable to find '['23.95','30.29','31.204','7.9','2.465','33.669']' in the program's output.
Enter the original price of the item: Enter the percentage of the mark-up: Enter the sales tax rate (as a percentage): Original price of the item: $23.95
Percentage of the mark-up: 30.29%
Store's selling price of the item: $31.20
Sales tax rate: 7.90%
Sales tax: $2.47
Final price of the item: $33.67
.
Error : AssertionError - Unable to find a number close enough to 31.204(+/-0.00) in the program's output.
Timestamp: 2024-01-1915:37:47.745116

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!