#include <bits/stdc++.h>
using namespace std;
const long long int hell = (long long int)(1e18 + 100LL);
int main() {
  long long int t, i, j, k, m, n, x, y;
  t = 1;
  while (t--) {
    long long int flag = 0;
    cin >> n >> m;
    ;
    vector<long long int> ar(n, 0);
    long long int sum = 0;
    for (i = 0; i < n; i++) {
      cin >> x;
      ar[i] = x;
      sum += x;
    }
    if (sum + n - 1 == m) {
      cout << "YES";
      return 0;
    }
    cout << "NO";
  }
  return 0;
}
