The George Washington University
School
of Engineering and Applied Science
Department of Computer Science

CSci 51 -- Introduction to Computing – Spring 2002
Lab #9
For labs meeting April 4 & 5, 2002

 

Write and test a package which includes the following type along with a get and a put for the type. This type is meant to represent a primitive airline reservation.

 
  TYPE Reservation IS RECORD
    ID : String(1..6); 
    Name : String(1..20); 
    FlightNum : Integer; 
    Month : Integer;
    Day : Integer; 
    Year : Integer; 
  END RECORD; 

The ID is some combination of numbers and letters, meant to be a unique key for the reservation. The name is the passenger's name. The flight number is the passenger's starting flight number. The month, day, and year represent the starting date of the passenger's travel.