B.py 130 B

1234567
  1. import math
  2. n = int(input())
  3. A = list(map(int,input().strip().split()))
  4. x = min(A)
  5. y = max(A)
  6. s = sum(A)
  7. print("%d %d %d"%(x,y,s))