Choose the result

Report a typo

When dealing with dict.keys(), you can use some operations for combining them. For instance, & will denote the intersection of dictionary keys even if their values are different. Have a look at the code below. What is the right output?

tim_toys = {'teddy bear': 3, 'toy car': 5, 'lion': 7, 'puppy': 5}
tom_toys = {'doll': 3, 'puppy': 2, 'kitten': 4, 'teddy bear': 3}
print(tim_toys.keys() & tom_toys.keys())
Select one option from the list
___

Create a free account to access the full topic