#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
int max(int a, int b) {
  if (a > b)
    return a;
  else
    return b;
}
int min(int a, int b) {
  if (a < b)
    return a;
  else
    return b;
}
bool isPrime(int N) {
  for (int i = 2; i * i <= N; ++i) {
    if (N % i == 0) return false;
  }
  return true;
}
void solve() {
  long long int n, m, k;
  cin >> n >> m >> k;
  vector<int> arr(n);
  for (int(i) = 0; (i) < (n); (i)++) cin >> arr[i];
  for (int(i) = 0; (i) < (n - 1); (i)++) {
    m += arr[i] - max(0, arr[i + 1] - k);
    if (m < 0) {
      cout << "NO"
           << "\n";
      return;
    }
  }
  cout << "YES"
       << "\n";
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int t = 1;
  cin >> t;
  while (t--) {
    solve();
  }
  return 0;
}
