问题来源:https://blog.csdn.net/qxqxqzzz/article/details/103138686
方法:重新拷贝一份list,然后遍历去删除。参照python删除List元素的常用方法:https://blog.csdn.net/u013555719/article/details/84550700
解决:
a = ['1111', '2222', '3333', '222222', '4444']
for item in a[:]: # a[:]是 a的拷贝
print('Now a=', a, 'item=', item,)
print('check...', item)
flg = False
for j in range(len(item)):
print('check...', item[j])
if item[j] == '2':
print('