Forwarded from 心惊报
This media is not supported in your browser
VIEW IN TELEGRAM
最近从中高风险区回家的朋友,都要做核酸检测了,但是很多朋友不知道流程,内心有恐惧,其实真的不用害怕。
下面给大家简单模拟一下核酸过程
下面给大家简单模拟一下核酸过程
写着写着发现一个「愚蠢的python的经典问题」:
The reason for this is that the iterator does not know that a list element was removed, and happily advances to the next item.
哦忘说了,py根本不给你一个 index 去往前倒回去的机会。
>>> lst = [1, 2, 3, 4, 5, 6]
>>> for x in lst:
if x < 6:
lst.remove(x)
>>> lst
[2, 4, 6]The reason for this is that the iterator does not know that a list element was removed, and happily advances to the next item.
哦忘说了,py根本不给你一个 index 去往前倒回去的机会。