n, h = map(int, input().split()) a = list(map(int, input().split())) z = 1 for i in range(n): z *= a[i] if z % h == 0: print("Yes") else: print("No")