def find_min_tem():
n=int(input())
if n<0:
   print("invalid input")
   return
tem=list(map(int,input().split()))
print(min(tem))