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