#include <bits/stdc++.h>
using namespace std;
int gcd(int x, int y) {
  while (y) {
    int p = y;
    y = x % y;
    x = p;
  }
  return x;
}
int main() {
  int n, k, x, z = 1, p;
  bool flag;
  scanf("%d %d", &n, &k);
  int K = k;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &x);
    p = gcd(x, K);
    p /= gcd(p, z);
    k /= p;
    z *= p;
  }
  k == 1 ? puts("Yes") : puts("No");
  return 0;
}
