for iIndex in range(0,len(strList),3):
lineList = strList[iIndex: index + 3]
## strList 长度必需为3的倍数
print(lineList[0])
print(lineList[1])
print(lineList[3])
list 循环获取3个值
最新推荐文章于 2022-10-28 09:39:45 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)
for iIndex in range(0,len(strList),3):
lineList = strList[iIndex: index + 3]
## strList 长度必需为3的倍数
print(lineList[0])
print(lineList[1])
print(lineList[3])