Answered step by step
Verified Expert Solution
Question
1 Approved Answer
in c++ NAS airline permits each passenger to carry one piece as hold bag. The maximum baggage allowance weight and the excess baggage fees (the
in c++
NAS airline permits each passenger to carry one piece as hold bag. The maximum baggage allowance weight and the excess baggage fees (the amount should be paid for each kg over the allowance weight) are depend on the passenger class as in the following table: Baggage Allowance Class Excess Baggage Fees Weight (per kg over allowance weight) First (F) 30 5 Business (B) 30 10 Economy (E) 20 20 Write a program that reads the passenger class and the hold bag weight. Your program should then calculates and prints the total paid fees as shown in the sample run. Note: Use switch and if statement. Your program should accept both uppercase and lowercase for the passenger class. [Sample Run#1] Enter the passenger class (F: First | B: Business | E: Economy): F Enter the hold bag weight: 30 ******** ****** I Passenger Class Bag Weight Paid Fees 1 1 F 30 0 ***** ***********Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started