Question: Language is c++. Please help Write a program that assigns passenger seats in an airplane. main function: 1. Prompt the user to enter the model

Language is c++. Please help  Language is c++. Please help Write a program that assigns passenger
seats in an airplane. main function: 1. Prompt the user to enter

Write a program that assigns passenger seats in an airplane. main function: 1. Prompt the user to enter the model of the airplane, and the number of rows and columns in this model. 2. Allocate and initialize a 2D array to represents the seat assignments of the airplane 3. Display the initial assignments (when no seat has been assigned, and all are available). Below is an example of small airplane with 8 rows and 4 seats per row. Eagle126: 32 seats remaining 1 ABCD 2 ABCD 3 A BC D 4 ABCD 5 A BC D 6 A BCD 7 ABCD 8 A BCD Alternatively, you can display the assignments as follows: Eagle126: 32 seats remaining A BCD 1 000O 3 OooO 4 000O 7 OooO 8 OooO O: available, X: unavailable 4. Repeated a) ask the user to choose a seat by entering a string such as "2D b) If the seat is already taken, display an error message and ask the user to try again. if the seat is available, update the 2D array to record the seat is now taken and display the updated assignment c) display all seats that have been taken in the order they were assigned. (you can use a vector to store them)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock 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 Databases Questions!