Question 1

Last Updated :
Discuss
Comments

What will be the output of the following code?

Python
d = {'a': 5, 'b': 10}
d['a'] = 15
print(d)

{'a': 5, 'b': 10}

{'a': 15, 'b': 10}

Error

{'a': 15}

Share your thoughts in the comments