$ ./guess_the_language
Problem Solving — predict the output
Problem Solving — predict the output · medium · #111
What is printed?
d = {'a': 1} print(d.get('b'), d.get('b', 0))
None 0
0 0
KeyError
None None
get returns None for a missing key unless a default is given.
Play Problem Solving ▸
◂ #110
all Problem Solving — predict the output questions
#112 ▸