Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2 total weight =105 num bags =2 YYou may modify the 1 ines of code above, but don' t move theml When you Submit your

image text in transcribed
2 total weight =105 num bags =2 YYou may modify the 1 ines of code above, but don' t move theml When you Submit your code, we'11 change theso 11 ines to ifasign different values to the variables. - Imagine you're writing the code for an airport check-in kiosk. Wn check-in, it detexmines how much a passenger owes in Fees for thesi bags. To do so, it applies the following logic: - If the passenger is not in first class, then each bag costs $30 - If the passenger is in first cjass, their first bag is free, - If the average weight of the suitcases exceeds 50 pounds, there is a $40 per bag surcharge. This applies to all bags, regardless of cabin. 21 *For example, if a passenger in first class (cabin = "First") 22 Whas two bags whose total weight is 105 , then they would owe 23 W $110 in bag fees: $0 for the first bag, \$30 for the second bag, 24 Hand $40 for each bag for the average weight being over 50. 26 print the result according to the following format, replacing 27 Hhe number with the correct total: 28 Hour total baggage fee is: $110 31 32 ydd your code here! 33 def (cabin) : if cabincm first: print (5+30)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Practical Database Programming With Visual C# .NET

Authors: Ying Bai

1st Edition

0470467274, 978-0470467275

More Books

Students also viewed these Databases questions

Question

Provide examples of KPIs in Human Capital Management.

Answered: 1 week ago

Question

What are OLAP Cubes?

Answered: 1 week ago