of 3
1
Student Name: __________________
Class and Section __________________
Total Points (20 pts) __________________
Due: Wednesday September 14, 2016 before the class
Project: Baby name popularity ranking
CSCI 2410 Data Structures and Algorithms
Armstrong Atlantic State University
Problem Description:
Assume the data files are stored for baby name rankings for year 2001, 2002, …, 2010 at
www.cs.armstrong.edu/liang/data/babynamesranking2001.txt, …, and
www.cs.armstrong.edu/liang/data/babynamesranking2010.txt. Write a program that
enables the user to select a year, gender, and enter a name to display the ranking of the name for
the selected year and gender, as shown in the following figure. To achieve the best efficiency,
create two arrays for boy’s names and girl’s names, respectively. Each array has 10 elements for
10 years. Each element is a map that stores a name and its ranking in a pair with the name as the
key.
Figure
The user selects a year, gender, and enters a year and clicks the Find Ranking button to display the ranking
in a dialog box.
Requirements:
2
Analysis:
(Describe the problem including input and output in your own words.)
Design:
(Describe the major steps for solving the problem)
Coding: (Copy and Paste Source Code here. Format your code using Courier 10pts)
Name the public class Exercise21_11
Testing: (Describe how you test this program)
3
Screen Shot
What to submit?
1. This document for the team
2. Compile and Submit to LiveLab (each team member must submit the program
regardless whether it complete or incomplete, correct or incorrect)
3. Fill in self-evaluation:
1. Can your program read the data from the URLs? _______________
2. Can your program store data in hash maps? _______________
3. Can your program display UI? _______________
4. Can your program display correct result? ___________