Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Saudi airlines need your help in their reservation system. Write a C+ program that does the following: 1. Allow the user to enter the size

image text in transcribed
Saudi airlines need your help in their reservation system. Write a C+ program that does the following: 1. Allow the user to enter the size of the airplane in terms of rows and columns 2. Create a dynamic 2D array of Boolean type with the specified rows and columns. 3. Display a menu to the user that allows them to choose from the following: a. Reserve a seat void reserve(bool "arr, int rows, int cols) IMAM ABDULRAHMAN BIN FAISAL UNIVERITY The user enters the row and column of the seat they would like to reserve. If the seat is available, it is then reserved for the user. If it's not available, a message is displayed to the user conveying that the seat has already been reserved. b. Display the number of available seats int available(bool "arr, int rows, int cols) This function returns the number ' of available seats that haven't been reserved yet. c. Display all the seats in the airplane void display(bool "arr, int rows, int cols) This function visualizes to the user all the seats in the plane. Reserved seats are displayed "1 " and unreserved seats are displayed " 0 ". 4. Continue to allow the user to choose from the menu until the user enters ' y. 5. Delete the dynamic array when it's no longer used

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

C++ Database Development

Authors: Al Stevens

1st Edition

1558283579, 978-1558283572

More Books

Students also viewed these Databases questions