Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

# filter a list

# filter a list
list1 = [5,7,9,27,10,30,40,50,75,47,66,89,121,566,100]
result = [i for i in list1 if i %5 ==0] #findout the numbers div by 5
print(result)
 
PREVIOUS NEXT
Tagged: #filter #list
ADD COMMENT
Topic
Name
6+7 =