fork download
  1. # your code goes here
  2. A = int(input())
  3. B = list(input().split())
  4. if int(len(list(B))) == A:
  5. print(min(B), max(B))
Success #stdin #stdout 0.02s 9220KB
stdin
2
2 10
stdout
10 2