Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A mail-order house sells five products whose retail prices are as follows: Produ

ID: 3529919 • Letter: A

Question

A mail-order house sells five products whose retail prices are as follows: Product 1, $2.98; product 2, $4.50; product 3, $9.98; product 4, $4.49 and product 5, $6.87. Write an application that reads a series of pairs of numbers as follows: a) product number b) quantity sold Your program should use a switch statement to determine the retail price for each product. It should calculate and display the total retail value of all products sold. Use a sentinel-controlled loop to determine when the program should stop looping and display the final results. Sample Output Enter product number (1-5) (0 to stop): 1 Enter quantity sold: 5 Enter product number (1-5) (0 to stop): 5 Enter quantity sold: 10 Enter product number (1-5) (0 to stop): 0 Product 1: $14.90 Product 2: $0.00 Product 3: $0.00 Product 4: $0.00 Product 5: $68.70

Explanation / Answer


Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote