#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    int l, r;
    scanf("%d%d", &l, &r);
    if (2 * l >= r + 1)
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  return 0;
}
