CSC 271
Homework 5 in C++

Assigned Nov 4, due Nov 10

Write a C++ program which takes one or more integers on the command line, and for each one,

  1. generates a linked list of this many random numbers,
  2. prints them,
  3. makes a copy of the linked list, in the same order,
  4. finds the length (which should be the same as the number you read in; check it!),
  5. finds and prints the smallest and largest elements,
  6. reverses the list and prints that, along with the amount of time it took to reverse, and
  7. sorts the list, and prints the sorted list, along with the amount of time it took to sort.

Notes:

I recommend writing this in several source files. Turn in all your source code files, all your header files, and your makefile.


Last modified: 
Stephen Bloch / sbloch@adelphi.edu