#include <bits/stdc++.h>
using namespace std;
long long mod = 998244353;
int main() {
  ios_base::sync_with_stdio(false);
  long long test;
  cin >> test;
  while (test--) {
    unsigned long long a, b, n, m;
    cin >> a >> b >> n >> m;
    long long suma = a + b, mini = min(a, b);
    if (m > mini) {
      cout << "No" << endl;
      continue;
    }
    suma -= m;
    if (n > suma) {
      cout << "No" << endl;
      continue;
    }
    cout << "Yes" << endl;
  }
}
