import collections import math def my_lcm(x, y): return (x * y) // math.gcd(x, y) N,K = map(int, input().split()) A = list(map(int, input().split())) v = 1 for a in A: gc = math.gcd(a,K) v = my_lcm(v,gc) if v%K==0: print('Yes') else: print('No')