#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long n, m, k, i;
  cin >> n >> m >> k;
  long long a[n];
  for (i = 0; i < n; i++) cin >> a[i];
  for (i = 0; i < n - 1; i++) {
    if (a[i] > (a[i + 1] - k)) {
      m += min(a[i] - (a[i + 1] - k), a[i]);
    } else {
      if (((a[i + 1] - k) - (a[i])) > m) {
        cout << "NO\n";
        return;
      } else
        m -= ((a[i + 1] - k) - (a[i]));
    }
  }
  cout << "YES\n";
  return;
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  long long test;
  cin >> test;
  while (test--) {
    solve();
  }
  return 0;
}
