import statistics N,a = map(int,input().split()) L = list(map(int,input().split())) if a == statistics.mean(L) : print("YES") else : print("NO")