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