This is what I am doing:
Where data is a list of lists in the form of [[int1, int2, int3], [int1, int2,int3]]
.
I want a dictionary that looks like: {int1: [int2, int3], in2:[int2, int3]}
.
I am checking what the size of data is before the dictionary comprehension and it is 1417.
I then check what the length of the dictionary is and it is something like 11, I don't know what is happening to the data list since all of the elements are not being copied into containsBacon
.
def makeComprehension(data):
containsBacon = dict([(movies[2], movies[0:2]) for movies in data])