You are viewing a single comment's thread. Return to all comments →
For Python:
n = int(input()) phoneBook = {} for i in range(n): name, number = input().split(" ") phoneBook[name.lower()] = number for _ in phoneBook: try: search_name = input() if search_name.lower() in phoneBook: print(f"{search_name.lower()}={phoneBook[search_name.lower()]}") else: print("Not found") except: break
Seems like cookies are disabled on this browser, please enable them to open this website
Day 8: Dictionaries and Maps
You are viewing a single comment's thread. Return to all comments →
For Python: