wordcount.cpp consists of the class wordCount and a demo program main(), which invites user to input a text ENDING WITH $ and display the result.