Skip to main content
 首页 » 编程设计

python之在 python 中合并列表

2025年05月04日19EasonJim

<分区>

Possible Duplicate:
Python - merge items of two lists into a list of tuples

有两个列表

x = [1,2,3,4,5] 
y = ['a','b','c','d','e'] 

如何获取列表

z = [(1, 'a'), (2, 'b'), (3, 'c'), (4, 'd'), (5, 'e')]