Department of Computer Science

Problem Solving and Algorithm Design I

Spring Semester 1998

Dr. Maury Eggen

Homework Laboratory Assignment 5:

For the next homework assignment, we shall learn the use of arrays
and strings. 

We shall assume that there is a body of ordinary text stored in a 
file in our directory. Our goal is to read the file and count how
many words of each length are in the file. We shall also find out
what word length is used most frequently, what word length is used
least frequently, what the longest word, and what the shortest word
is in the file. 

Your C++ program should use an array for the counting problem. You may
begin to use the printf() function to format your output. You may use
the unix "redirection of input stream" to read the data file. Have your
program display the data file as it is read back to the workstation
screen.

Program due date: February 16, 1998

Make sure your handin includes 
1. A title page with the correct laboratory exercise number
2. A page of formal documentation
3. A page of informal documentation
4. The source code
5. Several sample executions of the program