Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- testmas2=[1,-1,-1,1,2,-2,-2,2]
- def exampleThree(list):
- #for i in list:
- # if i % 2 == 0:
- # return (list[i])
- for i in range(0,len(list)):
- if list[i] % 2 ==0:
- return list[i]
- print(exampleThree(testmas2))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement