如何重复另一个列表内容中的列表元素,直到满足第二个列表的长度?例如:
LA = [0,1,2] LB = [(0,0),(1,0),(2,0),(3,0),(4,0),(5,0),(6,0)] the end result should be: LC = [(0,0,0),(1,0,1),(2,0,2),(3,0,0),(4,0,1),(5,0,2),(6,0,0)]
希望它可以在一行中完成
python list repeat python-2.7
list ×1
python ×1
python-2.7 ×1
repeat ×1