python 筛选

data=[0,9,3,2,1,3,2,-2,-1]
result=[x for x in data if x >=0 ]

原文地址:https://www.cnblogs.com/sea-stream/p/10216476.html