- >>> n
- [1, 2, 5, 10, 3, 100, 9, 24]
- >>> n1 = []
- >>> for i in n:
- ... if i < 5: continue
- ... n1.append(i)
- ...
- >>> n1
- [5, 10, 100, 9, 24]
- >>> n = n1
- #该片段来自于http://www.codesnippet.cn/detail/070120131389.html
来源: http://www.codesnippet.cn/detail/070120131389.html