how to merge two dict in python code example
Example 1: join two dictionaries python
z = {**x, **y}
Example 2: merge two dict python 3
z = {**x, **y}
Example 3: merge multile dict
dict1 = {"a":1, "b":2}
dict2 = {"x":3, "y":4}
merged = {**dict1, **dict2}
print(merged) # {'a': 1, 'b': 2, 'x': 3, 'y': 4}