how to add additional data in dictionary python without removing other data code example

Example 1: dictionary in python does not support append operation

dict_append = {"1" : "Python", "2" : "Java"}
dict_append.update({"3":"C++"})  # append doesn't supported in dict 
								 # instead , use update in dict
print(dict_append)
# output : {'1': 'Python', '2': 'Java', '3': 'C++'}

Example 2: python append to dictionary

dict = {1 : 'one', 2 : 'two'}
# Print out the dict
print(dict)
# Add something to it
dict[3] = 'three'
# Print it out to see it has changed
print(dict)