how to add multiple values to a key in python code example
Example 1: dictionary multiple values per key
key = "somekey"
a.setdefault(key, [])
a[key].append(1)
Example 2: multiple values in a dictionary python
a["abc"] = [1, 2, "bob"]
key = "somekey"
a.setdefault(key, [])
a[key].append(1)
a["abc"] = [1, 2, "bob"]