#include <bits/stdc++.h>
using namespace std;
const int N = 100010;
char ch[N];
int n;
long long m, k;
int a[N];
int main() {
  int T;
  cin >> T;
  while (T--) {
    cin >> n >> m >> k;
    for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
    int flag = 0;
    for (int i = 1; i < n; i++) {
      if (a[i + 1] > a[i] + k) {
        int d = a[i + 1] - a[i];
        if (d - k > m) {
          flag = 1;
          break;
        } else {
          m -= d - k;
        }
      } else {
        m += min(1LL * a[i], a[i] - (a[i + 1] - k));
      }
    }
    if (flag)
      cout << "NO" << endl;
    else
      cout << "YES" << endl;
  }
  return 0;
}
