from collections import defaultdict
d = defaultdict(lambda: "default")
d["x"] = 42
print(d["x"], d["y"])
Post #2991
635
Что выведет код?