#include <bits/stdc++.h>
using namespace std;

vector<int> a(3), b(2);

int main() {
  ios_base::sync_with_stdio(false);
  int t;
  cin >> t;
  while(t--) {
    cin >> a[0] >> a[1] >> a[2];
    cin >> b[0] >> b[1];
    bool ans = 0;
    sort(a.begin(), a.end());
    sort(b.begin(), b.end());
    do {
      do {
        int one = b[0] - a[0];
        int two = b[1] - a[1];
        if (one >= 0 && two >= 0 && one + two == a[2]) {
          ans = 1;
        }
      }while(next_permutation(b.begin(), b.end()));
    }while(next_permutation(a.begin(), a.end()));
    if (ans) {
      cout << "YES\n";
    }
    else {
      cout << "NO\n";
    }
  }
  return 0;
}