#include <bits/stdc++.h>
using namespace std;
int maxN = 1e6 + 10;
int n, k;
vector<int> arrC(maxN, 0);
int gcd(int a, int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
int lcm(int a, int b) { return (a / gcd(a, b)) * b; }
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n >> k;
  for (int i = 0; i < n; ++i) {
    cin >> arrC[i];
    arrC[i] = gcd(arrC[i], k);
  }
  int lcmC = arrC[0];
  for (int i = 1; i < n; ++i) {
    lcmC = lcm(lcmC, arrC[i]);
  }
  if (lcmC % k == 0) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
  return 0;
}
