N, A = map(int, input().split()) X = [int(x) for x in input().split()] print("YES" if A == sum(X)/N else "NO")