demo_ref_dictionary_fromkeys.py:
x = ('key1', 'key2', 'key3') y = 0 thisdict = dict.fromkeys(x, y) print(thisdict)
➜ begtut>python demo_dictionary_fromkeys.py
['key1': 0, 'key2': 0, 'key3': 0]