import math def lcm(x,y): return x//math.gcd(x,y)*y def main(): N,K=map(int,input().split()) A=list(map(int,input().split())) ans=A[0] for i in range(1,N): ans=lcm(ans,A[i]) ans%=K if ans==0: print("Yes") else: print("No") return main()