File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Beginers/DictOfStateCapitals Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 1
1
"""We have an existing dictionary that maps US states to their capitals.
2
2
3
- Print the state capital of Idaho
4
- Print all states.
5
- Print all capitals.
6
- Create a single string 'Alabama -> Montgomery, Alaska -> Juneau, ...'
7
-
8
- Now we want to add the reverse look up, given the name of a capital what state
3
+ 1. Print the state capital of Idaho
4
+ 2. Print all states.
5
+ 3. Print all capitals.
6
+ 4. Create a single string 'Alabama -> Montgomery, Alaska -> Juneau, ...'
7
+ 5. Ensure the string you created in 4. is alphabetically sorted by state
8
+ 7. Now we want to add the reverse look up, given the name of a capital what state
9
9
is it in?
10
10
11
11
Implement the function def get_state(capital): below so it returns the state.
You can’t perform that action at this time.
0 commit comments