#include <bits/stdc++.h>
using namespace std;
const long long MAXN = 1000002;
long long n;
long long needs[MAXN], capacity[MAXN], used[MAXN];
long long T;
long long check(long long x) {
  for (long long i = 1; i <= n; i++) {
    used[i] = 0;
  }
  used[1] += x;
  if (used[1] > capacity[1]) return -1;
  used[n] += needs[1] - x;
  if (used[n] > capacity[n]) return 1;
  for (long long i = 2; i <= n; i++) {
    long long lch = min(needs[i], capacity[i - 1] - used[i - 1]);
    used[i - 1] += lch;
    used[i] += needs[i] - lch;
    if (used[i] > capacity[i]) {
      if (i == n)
        return 1;
      else
        return -1;
    }
  }
  return 0;
}
signed main() {
  scanf("%lld", &T);
  while (T--) {
    scanf("%lld", &n);
    for (long long i = 1; i <= n; i++) {
      scanf("%lld", &needs[i]);
    }
    for (long long i = 1; i <= n; i++) {
      scanf("%lld", &capacity[i]);
    }
    long long l = 0, r = needs[1];
    bool ok = false;
    while (l <= r) {
      long long mid = (l + r) / 2;
      long long ch = check(mid);
      if (ch < 0) {
        r = mid - 1;
      } else if (ch > 0) {
        l = mid + 1;
      } else {
        ok = true;
        l = r = mid;
        break;
      }
    }
    if (ok) {
      printf("YES\n");
    } else {
      printf("NO\n");
    }
  }
}
