Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

PLEASE USE C++ Language only. Question 1. The program should include a function that initially reads the seat chart from the file chartIn.txt and fill

image text in transcribedPLEASE USE C++ Language only.
Question 1.
The program should include a function that initially reads the seat chart from the file chartIn.txt and fill out a 2-dimentional array called seatChart. It then display the following menu:
------------------------ Menu ---------------------------
1. Display Seat Chart
2. Reserve Seat
3. Cancel Reservation
4. Save Seat Chart to File
5. Statistics
6. Help
7. Quit
----------------------------------------------------- ---
Please Enter Your Choice (1-7):
This is what I have so far but please correct it:
void readFileDisplayMenu(ifstream& ins, array[], int)
{
int array[10][5];
ins.open("chartIn.txt");
while (!ins.eof())
{
for (int i = 0; i
{
for (int j = 0; j
ins >> array[i][j];
cout
}
}
cout
cout
cout
cout
cout
cout
cout
cout
cout
cout
}
Question 2:
Option 1 (Display Seat Chart): The program calls a function that displays the seat chart from the array seatChart using the format shown in the picture above.
Please use loops
Thank you.
The aim of this project is to implement a seat reservation system for a passenger airplane. We assume a small airplane with 10 rows and 4 seats per row. We assume that the seat chart is initially stored in a file "chartIn.txt" in the following format: 1 A B C D 2 A B C D 3 A B C D A B C D 5 A B C D 6 A B C D 7 A B C D A B C D 9 A B C D 10 A B C D

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_2

Step: 3

blur-text-image_3

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

Handbook Of Relational Database Design

Authors: Candace C. Fleming, Barbara Von Halle

1st Edition

0201114348, 978-0201114348

More Books

Students also viewed these Databases questions

Question

How will the members be held accountable?

Answered: 1 week ago

Question

a. How will the leader be selected?

Answered: 1 week ago