#include <bits/stdc++.h>
using namespace std;
int64_t MODULO = 1e9 + 7;
bool myAssert(bool b);
void testDrivenDevelopment();
int start(int argc = 0, char const *argv[] = NULL);
vector<int> *g;
bool *isvisited;
int main(int argc, char const *argv[]) {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int64_t T;
  int64_t n, m, k, hreq, have = 0;
  cin >> T;
  while (T--) {
    cin >> n >> m >> k;
    have = m;
    int64_t h[n + 1];
    for (int i = 1; i <= n; i++) {
      cin >> h[i];
    }
    bool b = true;
    for (int i = 1; i < n; i++) {
      have = h[i] + have;
      hreq = h[i + 1] - k;
      hreq = max(hreq, (int64_t)0);
      if (have < hreq) {
        b = false;
        break;
      } else {
        have = have - hreq;
      }
    }
    if (b) {
      cout << "YES\n";
    } else {
      cout << "NO\n";
    }
  }
  return 0;
}
