#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, x, a, b;
  int t;
  cin >> t;
  while (t--) {
    cin >> a >> b;
    if (a >= b)
      cout << "YES" << endl;
    else if (a >= 4)
      cout << "YES" << endl;
    else if (a == 2 && b == 3)
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  return 0;
}
