Question: Given the following code, what will display after the code executes? pets = { dog: {type: poodle, color: white}, cat: {type: Siamese, color: black and
pets = {
"dog": {"type": "poodle", "color": "white"},
"cat": {"type": "Siamese", "color": "black and white"},
"bird": {"type": "parrot", "color": "green"}
}
pet = pets["dog"]
pet = pets["bird"]
print(pet["color"], pet["type"])
| a. | poodle white |
| b. | white poodle |
| c. | green parrot |
| d. | parrot green |
ANS:
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
