from math import gcd, lcm N, K = map(int, input().split()) A = list(map(int, input().split())) x = 1 for a in [gcd(K, a) for a in A]: x = lcm(x, a) if x % K == 0: print('Yes') else: print('No')