Using zip and list comprehension, create a new list, L3, that sums the two numbers if the number from L1 is greater than 10 and the number from L2 is less than 5. This can be accomplished in one line of code.
I have tried the codes below. Can anyone explain why python complains?
L1 = [1, 5, 2, 16, 32, 3, 54, 8, 100]
L2 = [1, 3, 10, 2, 42, 2, 3, 4, 3]
L3 = map(lambda (x1,x2): x1 + x2 if(x1 > 10 and x2 < 5) , zip(L1,L2))
L4 = map(lambda x: x[0] + x[1] if(x[0] > 10 and x[1] < 5) , zip(L1,L2))
print(L3)
print(L4)