-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathHighest-Even-Update
39 lines (35 loc) · 2.02 KB
/
Highest-Even-Update
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#Function used to find the largest even number in a list
def highest_even(li):
even_num = 0
for x in li:
if x %2 == 0:
if x > even_num:
even_num = x
print(even_num)
highest_even([10,2,3,4,8,11,20,14,99,46,22,93,75,61,57,15,52,26,72,95,37,84,27,])
/\ /\
| \ / |
| \ / \ / |
| \ /\ / \ / \ / |
| \ ^ / \/ \/ \ ^ / |
| |
/ \
/ \ / \
/ | \ / | \
/ | \ / | \
/ | @\ /@ | \
/ | \ / | \
/ \___/ \___/ \
/ \
/ |\______________________/| \
/ \ | | | | | | | /\ \
/ / \ | | | | | | | / \ \
/ / \ | | | | | | | / \ \
/ / \ \ | | | | | / / \ \
/ \ \ \_|___|___|___|___|__/ / / \
\/\/\/ /\ /\ \/\/\/
/ \ / \
| |
| \____________________/ |
\ | | /
<_________/ \_________>