#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t-- > 0) {
    long long int l, r;
    cin >> l >> r;
    long long int no = (l * 2);
    long long int x = no / 2;
    if (r >= no) {
      cout << "NO";
    } else {
      cout << "YES";
    }
    cout << endl;
  }
}
