import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class No476 { public static void main(String[] args) { try{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String[] str = br.readLine().split(" "); int N = Integer.parseInt(str[0]); double maiAns = Double.parseDouble(str[1]); String[] str2 = br.readLine().split(" "); long[] num = new long[N]; long sum = 0; for(int i=0; i < N; i++){ num[i] = Integer.parseInt(str2[i]); sum += num[i]; } double ave = (double)sum / N; if(maiAns == ave) System.out.println("YES"); else System.out.println("NO"); }catch(IOException e){ e.getStackTrace(); }catch(NumberFormatException e){ e.getStackTrace(); } } }