After making dictionaries in Python, can I add keys? I don't know because I can't see the add() method.
python
d = {1:2}
print(d)
d[2] = 3
print(d)
Or
d = {1:2}
print(d)
d.update({2:3})
print(d)
You can use it with . The results for both are as follows.
{1: 2}
{1: 2, 2: 3}
© 2025 OneMinuteCode. All rights reserved.