""" TLE解 setで圧縮 """ from math import lcm n, k = map(int, input().split()) a = set(map(int,input().split())) x = 1 for v in a: x = lcm(x, v) if x % k == 0: print("Yes") else: print("No")