#include using namespace std; typedef long long ll; typedef pair ii; typedef vector vi; typedef vector vii; typedef vector vvi; typedef vector vvii; #define fi first #define se second #define eb emplace_back #define pb push_back #define mp make_pair #define mt make_tuple #define endl '\n' #define ALL(x) (x).begin(), (x).end() #define RALL(x) (x).rbegin(), (x).rend() #define SZ(x) (int)(x).size() #define FOR(a, b, c) for (auto a = (b); (a) < (c); ++(a)) #define F0R(a, b) FOR (a, 0, (b)) template bool ckmin(T& a, const T& b) { return a > b ? a = b, true : false; } template bool ckmax(T& a, const T& b) { return a < b ? a = b, true : false; } #ifndef DEBUG #define DEBUG 0 #endif #define dout if (DEBUG) cerr #define dvar(...) " \x1b[35m[" << #__VA_ARGS__ ": " << mt(__VA_ARGS__) << "]\x1b[0m " template true_type const_iterator_check(typename T::const_iterator*); template false_type const_iterator_check(...); template struct IsC : decltype(const_iterator_check(nullptr)) {}; template <> struct IsC : false_type {}; template typename enable_if::value, ostream&>::type operator<<(ostream&, const C&); template ostream& operator<<(ostream&, const pair&); template using TS = tuple_size>; template typename enable_if::value == idx + 1, ostream&>::type operator<<(ostream& o, const tuple& t) { return o << ", " << get(t) << ')'; } template typename enable_if<0 < idx && idx + 1 < TS::value, ostream&>::type operator<<(ostream& o, const tuple& t) { return operator<<(o << ", " << get(t), t); } template typename enable_if<1 < TS::value && !idx, ostream&>::type operator<<(ostream& o, const tuple& t) { return operator<<(o << '(' << get(t), t); } template ostream& operator<<(ostream& o, const tuple& t) { return o << get<0>(t); } template ostream& operator<<(ostream& o, const pair& p) { return o << mt(p.fi, p.se); } template typename enable_if::value, ostream&>::type operator<<( ostream& o, const C& c) { o << '['; for (auto it = c.cbegin(); it != c.cend(); ++it) o << *it << (next(it) != c.cend() ? ", " : ""); return o << ']'; } template void tprint(vector>& v, size_t width = 0, ostream& o = cerr) { if (!DEBUG) return; for (const auto& vv : v) { for (const auto& i : vv) o << setw(width) << i; o << endl; } } int main() { ios_base::sync_with_stdio(0); cout.tie(0); cin.tie(0); ll n, h; cin >> n >> h; ll ans = 1; F0R (_, n) { ll x; cin >> x; ans = ans * abs(x) % h; } cout << (ans ? "NO" : "YES") << endl; return 0; }