Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Help with reservation system

shannondingleshannondingle Member Posts: 10
Hi,
Im new to Javascript and am wondering if anyone can help me with this assignment ive been given, really stuck.

Any help would be great,
Shannon




A small airline has just purchased a computer for its new automated reservation system. You have been asked to program the new system. You are to write a JavaScript program to assign seats on the next flight of the airlines only plane (capacity 10 seats). Your program should display a web page that asks for the passenger name and provides the following alternatives: Please type 1 for First Class and Please type 2 for Economy. If the person types 1, your program should assign a seat in the first class section (seats 1-5). If the person types 2, your program should assign a seat in economy section (seats 6-10). Your program should output boarding pass information indicating the passenger name, seat number, and whether it is in the first class or economy section of the plane.
Your program should, of course, never assign a seat that has already been assigned. When the first class section is full, your program should ask the person if it is acceptable to be placed in the economy section (and vice versa). If yes, then make the appropriate seat assignment. If no, then output the message: Next flight leaves in 3 hours.
Your program should be able to output a list of passengers who have reservations.

Comments

  • CyGuyCyGuy Member Posts: 312
    : Hi,
    : Im new to Javascript and am wondering if anyone can help me with this assignment ive been given, really stuck.
    :
    : Any help would be great,
    : Shannon
    :
    :
    :
    :
    : A small airline has just purchased a computer for its new automated reservation system. You have been asked to program the new system. You are to write a JavaScript program to assign seats on the next flight of the airlines only plane (capacity 10 seats). Your program should display a web page that asks for the passenger name and provides the following alternatives: Please type 1 for First Class and Please type 2 for Economy. If the person types 1, your program should assign a seat in the first class section (seats 1-5). If the person types 2, your program should assign a seat in economy section (seats 6-10). Your program should output boarding pass information indicating the passenger name, seat number, and whether it is in the first class or economy section of the plane.
    : Your program should, of course, never assign a seat that has already been assigned. When the first class section is full, your program should ask the person if it is acceptable to be placed in the economy section (and vice versa). If yes, then make the appropriate seat assignment. If no, then output the message: Next flight leaves in 3 hours.
    : Your program should be able to output a list of passengers who have reservations.
    :
    :
    [green]my program would as if they want a window seat, but your program sounds like a homework assignment... that is not what the intention of this BBS. If you try and have a problem, post again with the specific problem that you encounter... someone will assist.[/green]
    [green]WHAT you;see_is_what=you.get;[/green]
    -Russ aka DangeRuss

Sign In or Register to comment.