#include #include #define ll long long using namespace std; int main(){ ll n,h; cin >> n >> h; vector a(n); ll mod = 1; for(int i=0;i < n;i++){ cin >> a[i]; mod *= a[i] % h; } if(mod == 0) cout << "YES" << endl; else cout << "NO" << endl; return 0; }