#include <bits/stdc++.h>
using namespace std;
int cmp(const void *a, const void *b) { return *(int *)a - *(int *)b; }
int main() {
  int n, m;
  cin >> n >> m;
  int a[2222];
  for (int i = 0; i < n; i++) scanf("%d", &a[i]);
  qsort(a, n, sizeof(a[0]), cmp);
  int flag = 1;
  int sum = 0;
  for (int i = 0; i < n - 1; i++) {
    sum += a[i];
    if (sum > m) {
      cout << "NO" << endl;
      flag = 0;
      break;
    }
  }
  if (flag) cout << "YES" << endl;
  return 0;
}
