def Map(): return list(map(int,input().split())) def gcd(a, b): while a != 0: b %= a if b == 0: return a a %= b return b N,K = Map() A = Map() g = K for a in A: g = gcd(g,a) for i in range(N): A[i] //= g K //= g for a in A: g = gcd(K,a) K //= g if K == 1: print('Yes') else: print('No')