#include <bits/stdc++.h>
using namespace std;
int n, k;
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
long long lcm(long long a, long long b) { return a * b / gcd(a, b); }
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> n >> k;
  vector<int> c(n);
  for (int &x : c) cin >> x;
  long long cur = 1;
  for (int &x : c) {
    cur = gcd(k, lcm(cur, x));
  }
  if (cur == k) {
    cout << "Yes\n";
  } else {
    cout << "No\n";
  }
  return 0;
}
