This is somewhat a collective assignment. You did not see such question before. Use parallel arrays to solve this assignment. Write a program that reads a paragraph a text ending with dot ‘.’ and builds a dictionary out of its words. Follow the following steps to build your dictionary:
- The words are separated by blank characters (assume one blank between each two words).
- The dictionary is case insensitive. Upper case chars are converted into lower case chars.
- Duplicated words are not inserted into the dictionary
- Count and keep track of the number of times each word occurred in the text.
- Sort the dictionary descendingly with respect to number of occurrences of its words.
- Print the sorted dictionary one word per line.
Test your program on the following data:
This is somewhat a collective assignment
You did not see such question before
Use parallel arrays to solve this assignment
Write a program that reads a paragraph a text ending with dot and builds a dictionary out of its words
Follow the above steps to build your dictionary
Hopefully this paragraph is not too long for this assignment.
Note that i`m not a programmer or computer student :S