CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2009
    Posts
    1

    Red face need help or it is a nother F T_T

    hi i really suck at programing i need some help
    i have this project :

    Phase 1:
    Write a program to assign passengers seats in an airplane. Assume a small airplane with seat numberings as follows:

    1 A B C D
    2 A B C D
    3 A B C D
    4 A B C D
    5 A B C D
    6 A B C D
    7 A B C D

    The program should display the seat pattern, with an 'X' marking the seats already assigned. For example, after seats 1A, 2B, and 4C are taken, the display should look like:

    1 X B C D
    2 A X C D
    3 A B C D
    4 A B X D
    5 A B C D
    6 A B C D
    7 A B C D

    After displaying the seats available, the program should prompt for the seat desired, the user can type in a seat, and then the display of available seats should be updated. This continues until all seats are filled or until the user signals that the program should end.
    If the user types in a seat that is already assigned, the program should say that that seat is occupied and ask for another choice.
    Note: You should guard your application with a username and password, so that no body can access without a valid username and password.

    Phase 2:
    Write a Ticket class with the following:
    a- attributes:
    PassengerName, mobile , reservationNumber, eTKT_Number,departure,destination,price.
    b- The class should have a constructor with all attributes.
    c- Getters and setters.


    Write a Reservation class with the following:
    a- attributes:
    Res_Number, passengerName, TKT_Num,seatNumber ,departure, destination.
    b-Constructor.
    c-Getters and setters.
    d-Method checkValidity that return true if the ticket is valid for the current reservation:
    The purpose of the method is to check if the ticket departure, destination and the passenger name are the same in the ticket.
    c- Method print_Reservation:
    This method should print the PNR(Passenger Name Record) for the current reservation which contains all the attributes plus the total price. A copy of the PNR should be saved in a text file with the reservation number as a file name.
    Hint: read the price from the ticket.
    d- Method assign_seat:
    This method should utilize the algorithm done in phase 1 to assign a seat to reservation after displaying the seat map.

    i think this program is easy for a pro programing skills is that right ?

  2. #2
    Join Date
    Oct 2008
    Posts
    77

    Re: need help or it is a nother F T_T

    nobody is going to write code for you, not matter how easy assignment (homework) is. if you even bothered to read other posts on this page, you'd see that rule is: show your code, we'll gladly help - show just problem statement you'll get dissed.

  3. #3
    dlorde is offline Elite Member Power Poster
    Join Date
    Aug 1999
    Location
    UK
    Posts
    10,163

    Re: need help or it is a nother F T_T

    Quote Originally Posted by xdoom_light View Post
    i think this program is easy for a pro programing skills is that right ?
    Yes.

    You posted all that stuff just to ask that question?

    Questions are the important thing, answers are less important. Learning to ask a good question is the heart of intelligence. Learning the answer---well, answers are for students. Questions are for thinkers...
    R. Schank
    Please use [CODE]...your code here...[/CODE] tags when posting code. If you get an error, please post the full error message and stack trace, if present.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured