Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- chet = 0
- ne_chet = 0
- a = [int(i) for i in range(30)]
- for i in a:
- if a[i] % 2 == 0 and a[i] > chet:
- chet = a[i]
- if a[i] % 2 == 1 and a[i] > ne_chet:
- ne_chet = a[i]
- print(chet - ne_chet)
- print(a)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement