#include <bits/stdc++.h>
using namespace std;
void solve() {
  int x, y;
  cin >> x >> y;
  if (x == y || x > 3)
    cout << "YES\n";
  else if (x > 1 && x < 4 && y < 4)
    cout << "YES\n";
  else
    cout << "NO\n";
}
int main() {
  int tc;
  cin >> tc;
  while (tc--) solve();
  return 0;
}
