#define _USE_MATH_DEFINES #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; int main() { int n, a; cin >> n >> a; vector x(n); for(int i=0; i> x[i]; if(accumulate(x.begin(), x.end(), 0) == n * (long long)a) cout << "YES" << endl; else cout << "NO" << endl; return 0; }