#include using namespace std; int main(void) { long long n, a, sum = 0; cin >> n >> a; long long x[n]; for (int i = 0; i < n; ++i) { cin >> x[i]; sum = sum + x[i]; } if ((double) sum / n == a) { cout << "YES" << endl; } else { cout << "NO" << endl; } }