zip会将两个数以元祖的方式捆绑在一起:
list(zip([1,2,3,4,5],[6,7,8,9,0]))
>>>[(1,6),(2,7),(3,8),(4,9),(5,0)]
>>> list(map(lambda x, y : [x, y], [1, 3, 5, 7, 9], [2, 4, 6, 8, 10]))
[[1, 2], [3, 4], [5, 6], [7, 8], [9, 10]]
lambda和推导式列表求100内3的倍数:
1. list(filter(lambda x:not(x%3),range(100)))
2. [ i for i in range(1, 100) if not(i%3)]