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