This assignment enters with 3% into the total grade!
Assignment 6
- Write a program sort_csc322 that reads an arbitray
length input (from stdin is fine) line by line (allowing for
arbitrary line length), sorts the lines in ASCIIbetical order, and
prints it back onto stdout.
- Order: A letter that has a smaller numerical value is smaller
than a letter that has a bigger numerical value. To compare
strings, find the first character that differs (including the
terminating '\0').
- Hints:
- If you are lazy, reuse the binary tree code for sorting!
- Define a data type for the lines, using struct and
char*.
- Include a Makefile for building your final program from
the sources!
- More hint: If you are lazy, read man makedepend.
Stephan
Schulz,schulz@cs.miami.edu, Thu Aug 22 13:35:31 EDT 2002