n, a = map(int, input().split()) x = map(int, input().split()) print('YES' if sum(x) / n == a else 'NO')