from math import gcd N, K = map(int, input().split()) A = list(map(int, input().split())) A = list(set(A)) N = len(A) for i in range(N): if A[i] % K == 0: exit(print("Yes")) g = A[0] for i in range(N): g = gcd(g, A[i]) K //= gcd(g, K) A = [A[i] // g for i in range(N)] for i in range(N): K //= gcd(K, A[i]) print("Yes" if K == 1 else "No")