Question
Make in python dictionary called counties_cases using a for statement. Specifically, there will be 5 key:value pairs using the strings in counties and integers in
Make in python dictionary called counties_cases using a for statement. Specifically, there will be 5 key:value pairs using the strings in counties and integers in cases. If you are unable code the solution, then create the dictionary manually, without a for statement (for partial credit), and move on to the next part.
Print out counties_cases.
Print the length of counties_cases using the len function.
# Definition of counties and cases
counties =['Fairfax', 'Prince William', 'Virginia Beach',
'Loudoun', 'Arlington']
cases = [ 66703, 39398, 30652, 23126, 13182]
# Enter your code below this line:
# Definition of counties and cases
counties =['Fairfax', 'Prince William', 'Virginia Beach',
'Loudoun', 'Arlington']
cases = [ 66703, 39398, 30652, 23126, 13182]
# Enter your code below this line:
C)Update the counties_cases dictionary to include Richmond as the key and its paired value of 14849.
Print out counties_cases.
Print the length of counties_cases using the len function.
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