Use a sentinel value to end the program test the program


Write program C++ (using .cpp file) that allows the user to enter a part number that consists of four or five characters. The second and third characters represent the delivery method, as follows: "MS" represents "Mail - Standard", "MP" represents "Mail - Priority", "FS" represents "FedEx - Standard", "FO" represents "FedEx - Overnight", and "UP" represents "UPS". Display an appropriate message when the part number does not contain either four or five characters. Also display an appropriate message when the second and third characters are not one of the delivery methods. If the part number is valid, the program should display the delivery method. Use a sentinel value to end the program. Test the program using the following part numbers: 7MP6, 3fs5, 8ko89, and 1234MS.

Solution Preview :

Prepared by a verified Expert
Business Management: Use a sentinel value to end the program test the program
Reference No:- TGS02944616

Now Priced at $20 (50% Discount)

Recommended (94%)

Rated (4.6/5)