n,m=map(int,input().split()) l=sum(map(int,input().split())) print(["NO","YES"][m==l//n])