python3_ Python同时遍历多个列表一一对应

(13条消息) 学习笔记 | Python同时遍历多个列表一一对应_大虎牙的博客-CSDN博客_python通过列表一一对应

(13条消息) Python同时遍历多个列表一一对应_CJ-404的博客-CSDN博客_python两个列表一一对应

atAPNProfile = [1,2,3,38,39,4,5]
atAPNapnname = ['3GNET','3GWAP','WONET','v2x_ip','v2x_non_ip','IMS','SOS']
atAPNIPtype = ['IPV4V6','IPV6','IPV6','IPV4V6','IPV4V6','IPV4V6',]
for id, apnname, ipvtype in zip(atAPNProfile, atAPNapnname, atAPNIPtype):
    print(id, apnname, ipvtype)
'''
1 3GNET IPV4V6
2 3GWAP IPV6
3 WONET IPV6
38 v2x_ip IPV4V6
39 v2x_non_ip IPV4V6
4 IMS IPV4V6
'''

 

posted @ 2022-03-05 20:08  小鱼小鱼hi  阅读(319)  评论(0)    收藏  举报