n, a = map(int, input().split()) data =list(map(int, input().split())) t_avg = sum(data) / n if float(a) == t_avg: print("YES") else: print("NO")