Write an application to assign seats for each flight, Programming Languages

( Airline Reservations System ) A small airline has just purchased a computer for its new automated reservations system. You have been asked to develop the new system. You are to write an application to assign seats on each flight of the airline's only plane (capacity: 10 seats).

Your application should display the following alternatives: Please type 1 for First Class and Please type 2 for Economy . If the user types 1 , your application should assign a seat in the first-class section (seats 15). If the user types 2 , your application should assign a seat in the economy section (seats 610).

Use a one-dimensional array of simple type bool to represent the seating chart of the plane. Initialize all the elements of the array to false to indicate that all the seats are empty. As each seat is assigned, set the corresponding element of the array to TRue to indicate that the seat is no longer available.

Your application should never assign a seat that has already been assigned. When the economy section is full, your application should ask the person if it is acceptable to be placed in the first-class section (and vice versa). If yes, make the appropriate seat assignment. If no, display the message " Next flight leaves in 3 hours."

Posted Date: 3/29/2013 2:16:12 AM | Location : United States







Related Discussions:- Write an application to assign seats for each flight, Assignment Help, Ask Question on Write an application to assign seats for each flight, Get Answer, Expert's Help, Write an application to assign seats for each flight Discussions

Write discussion on Write an application to assign seats for each flight
Your posts are moderated
Related Questions
Problem: This assignment is about deleting nodes from the binary search tree. You need to use given sequence to construct a binary search tree and then delete some nodes from

how much it will cost? i need learn how to make rightsided triangle in forloop

Create the class Robot described in the Karel++ book. Description: The Robot class described in the Karel++ text is a derived class of ur_Robot. Create class Robot as a d

how to store an url in a dartabase(sql server 2005)? (or) create table b(url what is the datatype for url?

You will soon receive in an email a personalized assignment that tells you the nature of the "Empirical Data" you are to produce with a Pascal program for HW3. HW3 is about generat

1. A readme.txt file with: a. Instructions on how to compile and run your client and server code on the command line. (Also provide shell scripts if the commands are complicated

Assigment 01 Subject Code: ITE 2106 Subject Name: Software Engineering You run a software development organization catering to external clients to build software solutions. The bus

A hardware store sells the following hardware tools: screwdriver, wrench, and tape measure. You are asked to calculate the profit for the store based on the number of tools sold an

Write a script that will list and count all of the images in a given HTML web page. Each image starts with

The next major set of tasks to tackle are delete and update. Version control systems typically version updates to a ?le and only store the differences between the ?les. Two system