C++ Programming
Airplane Seating Assignment - Flight B8-16
Write a program that can be used to assign/remove seats for a commercial airplane. The airplane has 13 rows, with four seats in each row. Rows 1 & 2 are first class, rosws 3 through 7 are business class, and rows 8 - 13 are economy class.
You will need to create a menu that asks the user whether they wish to assign or remove a seat. When the user makes this selection, you should print out the current availablilty of seats similar to the diagram at the bottom of these instructions.
When assigning a seat, your program must prompt the user to enter the following information:
Ticket type (first class, business class, or economy class)
Desired Seat (that is available)
Be sure to print out a confirmation message on whether or not the seat was assigned to the user. If the class type is not available, an applicable message should also be shown.
The program should adequately loop displaying the seating chart (as applicable) similar to the following illustration. When a user selects a seat, it should then show as taken. You should also display an applicable message to users when a particular class (first, business, or economy) seat is not available (in case of a full plane).
Note: You do not have to keep up with ticket prices in this project, just which seats are available, etc.
To begin with, use the following seats
|
A
|
B
|
C
|
D
|
Row 1
|
*
|
*
|
X
|
*
|
Row 2
|
X
|
X
|
X
|
X
|
Row 3
|
X
|
*
|
X
|
*
|
Row 4
|
X
|
*
|
X
|
*
|
Row 5
|
*
|
X
|
*
|
*
|
Row 6
|
*
|
X
|
*
|
X
|
Row 7
|
X
|
*
|
*
|
X
|
Row 8
|
*
|
X
|
*
|
X
|
Row 9
|
X
|
*
|
*
|
X
|
Row 10
|
*
|
X
|
X
|
*
|
Row 11
|
*
|
*
|
*
|
*
|
Row 12
|
*
|
*
|
X
|
*
|
Row 13
|
X
|
*
|
*
|
X
|
* indicates an available seat.
X indicates that the seat is taken