#include <bits/stdc++.h>
using namespace std;
int main() {
  int t, tt;
  cin >> tt;
  for (t = 1; t <= tt; t++) {
    int n, m, k;
    cin >> n >> m >> k;
    int delta, h[n];
    for (int i = 0; i < n; i++) {
      int temp;
      cin >> temp;
      h[i] = temp;
    }
    for (int i = 0; i < n - 1; i++) {
      if (h[i + 1] >= k) {
        delta = k - (h[i + 1] - h[i]);
        m = m + delta;
      } else {
        m = m + h[i];
      }
      if (m < 0) i = n;
    }
    if (m < 0)
      cout << "NO" << endl;
    else
      cout << "YES" << endl;
  }
  return 0;
}
