Homework Laboratory Assignment 6:
For the next assignment of the semester, we shall learn the use of modular programming. Assume that there is a body of text stored in your directory. We shall attempt to learn as much as we can about this text. 1. Find the total number of sentences 2. find the total number of words 3. find the total number of characters 4. find the number of words of each word length (how many one letter words, how many two letter words, etc.) 5. find the frequency of the characters in the text (how many a's, how many b's, how many c's etc.) 6. find how many spaces, periods, commas, question marks, and how many exclamation points. 7. Find the letter that appears most frequently. 8. Find the letter that appears second most frequently. 9. Find the letter that appears least frequently. 10. Find the word length that appears most frequently 11. Display the text as it appears in the file 12. display all the results of your execution in a neat fashion. Each of the tasks of the program must be accomplished in its own function. The design is your own, but none of the functions should be too long. Since the data may need to be read more than once, we shall use the new file handling capabilities found in fstream.h or in stdio.h. We will no longer read the file by using unix's "redirection of the input stream." Program due date: February 25, 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