Question: You will write a program to create an airline reservation system for a small airline. You are to write a program to assign seats

 


You will write a program to create an airline reservation system for

You will write a program to create an airline reservation system for a small airline. You are to write a program to assign seats for a flight with a capacity of 10. (Assume 1 seat per row) Your program will have a menu that allows the user to choose the following: 1. First Class 2. Economy 3. Exit Seating Chart: ['A', 'A', 'A', 'A', 'A', 'A', 'A', 'A', 'A', 'A'] Choice == If the user selects option 1, user will be prompted to select a seat between rows 1 and 5. User should only be able to select a seat from 1 to 5. Program should display an appropriate message if user selects any other seat. If the user selects option2, user will be prompted to select a seat between rows 6 and 10. User should only be able to select a seat from 6 to 10. Program should display an appropriate message if user selects any other seat. (Rows: 1 to 5) (Rows: 6 to 10) When user is given the option to select the type of seat, it should also display the seating chart with which seats are available and which seats are taken. You need to create a list to represent the seating chart of the plane. Initialize all elements of the list to "A" for available. As the seats are occupied, the A should be replaced by "X" for no longer available. If a section reaches full capacity, then the program should display "Full" next to the menu option. For example, if there were no more seats available in First Class then it will display: 1. First Class 2. Economy 3. Exit (Rows: 1 to 5) (Rows: 6 to 10) Full Seating Chart: ['X', 'X', 'X', 'X', 'X', 'A', 'A', 'A', 'A', 'A'] Choice ==> The program should continue to run until user selects option 3 to exit the program. Your program needs to be modular( at a minimum you need to have the following four functions: firstClass, economy, menu, main Your program needs to have the same menu as shown in the output below.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Heres a Python program that fulfills your requirements def displayseatingchartseatingchart printSeat... View full answer

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 Programming Questions!