Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pies = {
- 'species': 'pieseł',
- 'name': 'felek',
- 'owner_first': 'ania',
- 'owner_last': 'brzęczyszczykiewicz',
- 'age': 3,
- }
- kot = {
- 'species': 'kotełek',
- 'name': 'dakarrr',
- 'owner_first': 'małgosia',
- 'owner_last': 'skowronek',
- 'age': 1,
- }
- szympans = {
- 'species': 'małpełe',
- 'name': 'czikita',
- 'owner_first': 'daniel',
- 'owner_last': 'petarda',
- 'age': 7,
- }
- animals = [pies, kot, szympans]
- for zwierz in animals:
- for key, value in zwierz.items():
- owner_full = f"{key['owner_first']} {key['owner_last']}"
- print(f"{owner_full.title()}")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement