I have a dictionary consisting of key:[list] in which the list is a fixed and even number of binary values, ie:
{'a':[0,1,1,0,0,1],'b':[1,1,1,0,0,0]}
For each key, I need to return a new value for each pair of values in the original dict, such that for pair(1,1) = 3, pair(0,1) = 2, pair(1,0) = 1, pair(0,0) = 0.
For the example above, output would be:
{'a':[2,1,2],'b':[3,1,0]}
New to both python and programming in general, and haven't found what I'm looking for on SO. Suggestions appreciated.