/**
 * CS139 - Programming Fundamentals
 * Department of Computer Science
 * James Madison University
 * @version Spring 2016
 */

Introduction

The Social Security Administration tracks the popularity of baby names on an annual basis. The goal of today's lab is to use HashMaps to develop an application that will allow us to interact with this data set.

Resources

Files

Instructions

  1. Complete BabyNames.java so that the functionality of the methods matches the provided documentation comments.

    HINT #1: Recall that strings have a split method that can be used to convert a string into an array by splitting at a particular delimiter. For example: "Bob,M,23".split(",") would return the array {"Bob", "M", "23"}.

    HINT #2: Recall that the Integer.parseInt method can be used to convert from the string representation of an integer to an int. For example Integer.parseInt("56") will evaluate to the integer value 56.

  2. You can test your completed class by running the NameApp or using the provided JUnit tests.

If You Have Extra Time

  1. Write another application that prints randomly selected names, but only selects names that are sufficiently popular. It should take a command line argument indicated the required popularity:
    $ java PrintPopularName 1000
    Emma
    

Submitting

Submit your completed BabyNames.java file through Web-CAT.