In this example we will show how to add an item to the dictionary in Python.
Source Code
mydict = {
'name': 'Steven',
'age': 24,
'ID': 123456
}
mydict['grade'] = 'A'
print(mydict)
Output:
{'name': 'Steven', 'age': 24, 'ID': 123456, 'grade': 'A'}