Question
The United States Social Security Administration (SSA) has made available data on the frequency of baby names from 1880 through the present1 . You are
The United States Social Security Administration (SSA) has made available data on the frequency of baby names from 1880 through the present1 . You are given a data file (i.e. Alabama2016.csv) with the 100 most popular male and female names in the state in 2016. Each line in the file contains five entries: (1) rank, (2) male name, (3) number of males, (4) female name, and (5) number of females. Develop a ReadNames(fileName) function in Pyhton that reads a file like the one provided and returns a list of two dictionaries [MaleNames, FemaleNames]. The key to each dictionary should be the name, and the value should be a list of two integers, namely (1) the rank, and (2) the number of males or females, respectively.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started