#include <bits/stdc++.h>
using namespace std;
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
int main() {
  int n, k, x;
  long long val = 1;
  scanf("%d%d", &n, &k);
  for (int i = 0; i < n; i++) {
    scanf("%d", &x);
    val = val / gcd(val, x) * 1ll * x;
    val = gcd(val, k);
  }
  printf("%s", (val % k == 0) ? "Yes" : "No");
  return 0;
}
