N,H=map(int,input().split())
A=list(map(int,input().split()))

X=1
for a in A:
    X*=a

if X%H==0:
    print("YES")
else:
    print("NO")