#include <bits/stdc++.h>
using namespace std;
int c[1000010];
bool notP[1000010];
int primes[1000010];
int sz = 0;
int cnt[1000010];
int main() {
  for (int i = 2; i <= 1000; i++) {
    for (int j = i + i; j <= 1000000; j += i) {
      notP[j] = 1;
    }
  }
  for (int i = 2; i <= 1000; i++) {
    if (!notP[i]) {
      primes[sz++] = i;
    }
  }
  int n, k;
  cin >> n >> k;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &c[i]);
  }
  for (int i = 1; i <= n; i++) {
    for (int j = 0; j < sz; j++) {
      int cur = 0;
      while (c[i] % primes[j] == 0) {
        cur++;
        c[i] /= primes[j];
      }
      cnt[primes[j]] = max(cnt[primes[j]], cur);
    }
    cnt[c[i]] = 1;
  }
  bool ok = 1;
  for (int i = 0; i < sz; i++) {
    int cur = 0;
    while (k % primes[i] == 0) {
      cur++;
      k /= primes[i];
    }
    if (cnt[primes[i]] < cur) {
      ok = 0;
    }
  }
  if (cnt[k] < 1) {
    ok = 0;
  }
  if (ok) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
  return 0;
}
