Frequency Counter 2 Demo

The following text was written to the standard output stream when the FrequencyCounter2 program was executed from Netbeans.

FrequencyCounter2.java


run:
Enter file name here: My Bonnie.txt
--- Begin contents of the hash map ...
<bed:1>
<brought:1>
<bring:26>
<back:26>
<dead:1>
<dreamt:1>
<ye:3>
<sea:3>
<that:1>
<winds:6>
<and:2>
<me:15>
<have:3>
<lies:3>
<oh:9>
<blow:3>
<on:3>
<over:9>
<bonnie:15>
<last:3>
<lay:3>
<night:3>
<was:1>
<i:4>
<blown:3>
<my:18>
<o:3>
<the:12>
<as:3>
<ocean:6>
<back,:1>
<pillow:2>
<to:15>
--- End contents of the hash map ...
>>> count
word?  Bonnie
15
>>> count
word?  pillow
2
>>> count
word?  word
word is not in the hash map.
>>> print
<bed:1>
<brought:1>
<bring:26>
<back:26>
<dead:1>
<dreamt:1>
<ye:3>
<sea:3>
<that:1>
<winds:6>
<and:2>
<me:15>
<have:3>
<lies:3>
<oh:9>
<blow:3>
<on:3>
<over:9>
<bonnie:15>
<last:3>
<lay:3>
<night:3>
<was:1>
<i:4>
<blown:3>
<my:18>
<o:3>
<the:12>
<as:3>
<ocean:6>
<back,:1>
<pillow:2>
<to:15>
>>> display
Sorry, the command you entered is not available. You can use the "HELP" command to see all commands available.
>>> help
COUNT -- Give the frequency of occurrence of the word entered
PRINT -- Display the hash map
EXIT -- Exit the program
HELP -- Display all available commands
>>> exit
BUILD SUCCESSFUL (total time: 55 seconds)