Below is a sample data file. Type it in and save it as proj4.dat.
Each line in this file is a record for a ship, containing the
following fields: ship-name, crew-size, displacement, commanders
rank and name.
Write a program which gets the name of its input file from the command
line, then reads a file like this (proj4.dat) into a linked list
of ships.
The program should allow the user to interactively do one of the
following: update the crew-size of a ship, update the rank of a
commander, print the complete record for a specific ship, find
the smallest ship in terms of displacement and print
out the names of the ships in order of displacement.
Document the code. Comments should be brief but informative. A good
rule of thumb is a comment for each function. Also a header comment
with your name, social security number, the assignment number,
a general description of the program and the names of any files
in your account needed to execute the program.
Execute the code using the "script" command to retain the run.
Hand in a print-out of the documented code along with the runs.