#include using namespace std; struct cww{cww(){ios::sync_with_stdio(false);cin.tie(0);}}star; int main() { int N; long long A; cin >> N >> A; vector vc( N ); for( auto &x : vc ) { cin >> x; } cout << ( (long double)accumulate( vc.begin(), vc.end(), 0 ) / N == A ? "YES" : "NO" ) << endl; return 0; }