#include <bits/stdc++.h>
using namespace std;
int ara[1000005], i, j, k, n, m, sum;
int main() {
  cin >> n >> m;
  for (i = 0; i < n; i++) {
    cin >> ara[i];
  }
  sort(ara, ara + n);
  j = n - 1;
  while (j--) {
    sum += ara[k++];
  }
  if (sum <= m)
    printf("YES");
  else
    printf("NO");
  return 0;
}
