Question: After the in - lab session, you are required to extend the functionality of your WordCounter by incrementing the word count for each word and
After the inlab session, you are required to extend the functionality of your WordCounter by incrementing the word count for each word and printing the report. Follow the additional specifications below:
incrementWordCount Function:
Implement a function void incrementWordCount in the WordCounter class that increments the count of occurrences for a word. Determine the appropriate arguments for this function.
printReport Method:
Implement a method void printReportvector& v in your main program.
This method should contain a cout statement that prints a report with each word and the number of times it occurred in the text file.
Integration:
Integrate the incrementWordCount function and printReport method into your main program.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
