Skip to content
← Back to Community
Contact List
Profile icon
PamelaGivens

Python 3

10.21 LAB: Contact list
A contact list is a place where you can store a specific contact with other associated information such as a phone number, email address, birthday, etc. Write a program that first takes in word pairs that consist of a name and a phone number (both strings). That list is followed by a name, and your program should output the phone number associated with that name.

Ex: If the input is:

Joe 123-5432 Linda 983-4123 Frank 867-5309
Frank
the output is:

867-5309

Voters
Profile icon
baiello3821
Profile icon
slaba3
Profile icon
ItzelOlea
Profile icon
smith457
Profile icon
PamelaGivens
Comments
hotnewtop
Profile icon
larrygato

hello solve the ban they did for abuse but I was not active in those days and if it was for that cause I apologize for the truth if I want to have those bots again

Profile icon
larrygato

hello solve the ban they did for abuse but I was not active in those days and if it was for that cause I apologize for the truth if I want to have those bots again

Profile icon
AdamZaki2

sry anyway i have recaptcha problems.
plz fix

Profile icon
AdamZaki2

hello solve the ban they did for abuse but I was not active in those days and if it was for that cause I apologize for the truth if I want to have those bots again

Profile icon
ebest

What do you need? Is this for homework?

Partial solution: Use a dictionary.