Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Flow Chart and Pseudocode for this program. #include #include using namespace std; void book(); void display(); char seat[13][6]; //main function int main() { int i,j,choice;

Flow Chart and Pseudocode for this program.

#include #include using namespace std;

void book(); void display();

char seat[13][6];

//main function int main() { int i,j,choice; //assigning default value '*' to all seats for(i=0;i>choice; switch(choice) { case 1: book(); break; case 2: display(); break; case 3: break; default: cout

//funtion to book a seat void book() { string ticketType; int seatnumber; int rownumber; string temp; cout>rownumber; cout>seatnumber; //if row number and seat number are correct than book seat if(seatnumber>=1 && seatnumber=1 && rownumber>rownumber; cout>seatnumber; //if row number and seat number are correct than book seat if(seatnumber>=1 && seatnumber=3 && rownumber>rownumber; cout>seatnumber; //if row number and seat number are correct than book seat if(seatnumber>=1 && seatnumber=8 && rownumber

}

//display function void display() { int i,j; cout

image text in transcribed

image text in transcribed

image text in transcribed

Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : 1 Enter the ticket type(first class, business class, or economy class) : first class Enter the Row number(1-2) 2 Enter the seat number(1-6) 1 Seat Booked sucessfully!!! Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : 1. Book a seat 2. See available seats 3. Exit Enter your choice : 2 B D F Row 1 Row 2 Row 3 Row 4 Row 5 Row 6 Row 7 Row 8 Row 9 Row 10 Row 11 Row 12 Row 13 indicates that the seat is available; x indicates that the seat is occupied. Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : 1 Enter the ticket type(first class, business class, or economy class) : first class Enter the Row number(1-2) 2 Enter the seat number(1-6) 1 Seat Booked sucessfully!!! Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice : 1. Book a seat 2. See available seats 3. Exit Enter your choice : 2 B D F Row 1 Row 2 Row 3 Row 4 Row 5 Row 6 Row 7 Row 8 Row 9 Row 10 Row 11 Row 12 Row 13 indicates that the seat is available; x indicates that the seat is occupied. Airplane Seating Menu 1. Book a seat 2. See available seats 3. Exit Enter your choice

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

Database Concepts

Authors: David Kroenke, David Auer, Scott Vandenberg, Robert Yoder

10th Edition

0137916787, 978-0137916788

More Books

Students also viewed these Databases questions