6-5. Rivers: Make a dictionary containing three major rivers and the country
each river runs through. One key-value pair might be ‘nile’: ‘egypt’.
• Use a loop to print a sentence about each river, such as The Nile runs
through Egypt.
• Use a loop to print the name of each river included in the dictionary.
• Use a loop to print the name of each country included in the dictionary.
favorite_languages = {‘jen’: ‘python’, ‘sarah’: ‘c’,’edward’: ‘rust’, ‘phil’: ‘python’,
}
6-6. Polling: Use the code in favorite_languages.py (page 96).
• Make a list of people who should take the favorite languages poll. Include
some names that are already in the dictionary and some that are not.
• Loop through the list of people who should take the poll. If they have
already taken the poll, print a message thanking them for responding.
If they have not yet taken the poll, print a message inviting them to take
the poll