Unformatted text preview: GImage as shown on the right: 2. Name Counts Write a program that asks the user for a list of names (one per line) until the user enters a blank line (i.e., just hits return when asked for a name). At that point the program should print out how many times each name in the list was entered. You may find that using a HashMap to keep track of the information entered by user may greatly simplify this problem. A sample run of this program is shown below....
View Full Document
This note was uploaded on 12/01/2009 for the course CS 106A taught by Professor Sahami,m during the Fall '08 term at Stanford.
- Fall '08
- Image processing