Hi, I want to merge two lists into one dictionary. Suppose I have two lists such as below
list_one = ['a', 'a', 'c', 'd']
list_two = [1,2,3,4]
and I want my dictionary to be like this
{'a': 1, 'a': 2, 'c': 3, 'd': 4}
As of right now, I have this following code
print dict(zip(['a', 'a', 'c', 'd'], [1,2,3,4]))
But the output from above code is this
{'a': 2, 'c': 3, 'd': 4}
How can I make it to this output?
{'a': 1, 'a': 2, 'c': 3, 'd': 4}
Thanks
'a'
???1
or2
? or should it be[1,2]
? you need to clarify...