Farz0l1x

Untitled

May 29th, 2023
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. file = open('15A.txt')
  2. n = int(file.readline())
  3. A = []
  4. for i in range(n):
  5. A += [int(file.readline())]
  6.  
  7. Max = 0
  8. for i in range(n):
  9. for j in range(i + 1, n):
  10. if abs(A[i] - A[j]) % 80 == 0:
  11. Max = max(Max, abs(A[i] - A[j]))
  12. print(Max)
  13.  
Advertisement
Add Comment
Please, Sign In to add comment