#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, k, a, k1;
  int p = 2;
  vector<int> pr(1000001, 0);
  pr[1] = 0;
  while (p < 1000001) {
    if (pr[p] == 0) {
      for (int i = p; i < 1000001; i += p) {
        pr[i] = p;
      }
    }
    p++;
  }
  cin >> n >> k;
  map<int, int> m;
  for (int i = 0; i < n; i++) {
    cin >> a;
    while (a > 1) {
      k1 = 0;
      p = pr[a];
      while (a % p == 0) {
        k1++;
        a /= p;
      }
      if (m.find(p) == m.end()) m[p] = 0;
      m[p] = max(m[p], k1);
    }
  }
  while (k > 1) {
    if (m[pr[k]] <= 0) {
      cout << "No";
      return 0;
    }
    m[pr[k]]--;
    k /= pr[k];
  }
  cout << "Yes";
}
