Def (f) :
For I in d:
I=input (" country code: please enter your queries \ n> & gt; & gt;" )
If I in d:
Print (" query results for: "d [I])
F ()
If I not in d:
A=input (" "" I'm sorry, your query the country code is not in the dictionary; \ b
1. Add please enter: "add";
2. The print dictionary content please enter: "all";
3. Return the query please press any key.
4. Please enter exit program: "exit";
& gt; & gt; & gt;" "")
If a=="add" :
X=input (" add the country code letters for: ")
Y=input (" add the country code comments as: ")
D [x]=y
F ()
Elif a=="all" :
Print (" current dictionary all content is as follows: ", d)
F ()
Elif a=="exit" :
Return
f()
CodePudding user response:
Think added: double-click the file to open. Py after adding dictionary written in py files, open the can check next time