list_in_function
unknown
plain_text
4 years ago
219 B
7
Indexable
def count():
even = 0
odd = 0
for i in list:
if i%2==0:
even+=1
else:
odd+=1
return even, odd
even, odd = count(list)
list = [12, 34, 56, 77, 99, 102]Editor is loading...