#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    long long int x, y;
    cin >> x >> y;
    if (x >= y)
      cout << "yes" << endl;
    else if (x == 1)
      cout << "no" << endl;
    else if (x == 2 && y == 3)
      cout << "yes" << endl;
    else if (x == 2 && y != 3)
      cout << "no" << endl;
    else if (x == 3 && y != 3)
      cout << "no" << endl;
    else
      cout << "yes" << endl;
  }
  return 0;
}
