Farz0l1x

Untitled

May 9th, 2023
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. from random import randint
  2. a = [randint(1, 100) for i in range(100)]
  3. n = len(a)
  4. Max = 0
  5. for i in range(n):
  6. for j in range(i + 11, n):
  7. if (a[j] + a[i]) % 567 == 0 and (a[i] + a[j]) % 2 == 0:
  8. Max = max(Max, a[j] + a[i])
  9. print(Max)
Advertisement
Add Comment
Please, Sign In to add comment