#include using namespace std; int main() { int64_t n, a; cin >> n >> a; int64_t s = 0; for (int i = 0; i < n; i++) { int n; cin >> n; s += n; } if (n * a != s) { cout << "NO" << endl; } else { cout << "YES" << endl; } }