func_code_string: #include <bits/stdc++.h>   using namespace std;   const int MAXN = 110;   int n, m, k;   int h[MAXN];   void load() {     scanf( %d%d%d , &n, &m, &k);     for (int i = 0; i < n; i++) scanf( %d , h + i);   }   bool solve() {     long long sum = m;     int ind = 0;     while (ind < n - 1) {       if (h[ind] >= h[ind + 1] - k) {         int nxt = max(h[ind + 1] - k, 0);         sum += h[ind] - nxt;       } else {         if (sum + h[ind] < h[ind + 1] - k) return false;         sum -= h[ind + 1] - k - h[ind];       }       ind++;     }     return true;   }   int main() {     int t;     scanf( %d , &t);     while (t--) {       load();       if (solve())         printf( YES n );       else         printf( NO n );     }     return 0;   }   