You are viewing a single comment's thread. Return to all comments →
Python is so clean
n = int(input()) name_numbers = [input().split() for _ in range(n)] phone_book = {k: v for k,v in name_numbers} while True: try: name = input() if name in phone_book: print('%s=%s' % (name, phone_book[name])) 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 →
Python is so clean