import sys input = sys.stdin.readline N=int(input()) A=list(map(int,input().split())) if min(A)<=1: print("Yes") else: print("No")