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