program display
Please type 1 for smoking
Please type 2 for non-smoking
If type 1,
program assign a seat in the smoking section (seat 1-5)
If type 2,
assign a seat non-smoking section (seat 6-10)
program print a Boarding Pass indicating the person seats number and whether it is smoking or non-smoking section of plane.
Use a single subscripted array to represent the seating chart of the plane. Initialize elements of the array to 0 to indicate that all seats are empty. As each seat is assigned set the corresponding elements to 1 to indicate that seats s no longer available.
program should, never assigned a seat that has already been assigned.
the smoking section is full program should ask if it is acceptable to be placed in the non smoking section
the non-smoking section is full program should ask if it is acceptable to be placed in the smoking section
In case of ( 5, 6 above) If ‘Yes’ then make the appropriate seat assignment. If ‘No’ than print the message “Next flight leaves in 3 H
2007-11-04
22:22:12
·
3 answers
·
asked by
alam
1
in
Air Travel