Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- countries_capitals = {'Poland': 'Warsaw', 'Germany': 'Berlin'}
- countries_capitals['Czechia'] = 'Prague'
- #print(countries_and_capitals)
- for key in countries_capitals.keys():
- print(key)
- print(countries_capitals["Poland"])
- print(countries_capitals.get("Poland"))
- print(countries_capitals.setdefault(("USA", "Washington DC")))
- if "Poland" in countries_capitals.keys():
- print("Znaleziono!")
- else:
- print("Nie znaleziono!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement