import sys input = sys.stdin.readline N=int(input()) A=list(map(int,input().split())) if A==[0]: print("No") else: print("Yes")