You got a job as a marketer in a pet shop, and your current task is to boost sales of cat food. One of the strategies is to sell cans of food in packs with discounts. 

Suppose you decided to sell packs with $a$ cans in a pack with a discount and some customer wants to buy $x$ cans of cat food. Then he follows a greedy strategy:   he buys $\left\lfloor \frac{x}{a} \right\rfloor$ packs with a discount;  then he wants to buy the remaining $(x \bmod a)$ cans one by one. 

$\left\lfloor \frac{x}{a} \right\rfloor$ is $x$ divided by $a$ rounded down, $x \bmod a$ is the remainer of $x$ divided by $a$.

But customers are greedy in general, so if the customer wants to buy $(x \bmod a)$ cans one by one and it happens that $(x \bmod a) \ge \frac{a}{2}$ he decides to buy the whole pack of $a$ cans (instead of buying $(x \bmod a)$ cans). It makes you, as a marketer, happy since the customer bought more than he wanted initially.

You know that each of the customers that come to your shop can buy any number of cans from $l$ to $r$ inclusive. Can you choose such size of pack $a$ that each customer buys more cans than they wanted initially?


-----Input-----

The first line contains a single integer $t$ ($1 \le t \le 1000$) — the number of test cases.

The first and only line of each test case contains two integers $l$ and $r$ ($1 \le l \le r \le 10^9$) — the range of the number of cans customers can buy.


-----Output-----

For each test case, print YES if you can choose such size of pack $a$ that each customer buys more cans than they wanted initially. Otherwise, print NO.

You can print each character in any case.


-----Example-----
Input
3
3 4
1 2
120 150

Output
YES
NO
YES



-----Note-----

In the first test case, you can take, for example, $a = 5$ as the size of the pack. Then if a customer wants to buy $3$ cans, he'll buy $5$ instead ($3 \bmod 5 = 3$, $\frac{5}{2} = 2.5$). The one who wants $4$ cans will also buy $5$ cans.

In the second test case, there is no way to choose $a$.

In the third test case, you can take, for example, $a = 80$.

Difficulty: EASY

Solutions:
def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())
test = inp()
matrix = []
for i in range(test):
	t = inlt()
	matrix.append(t)
for i in range(test):
	if int(matrix[i][0]) > int(matrix[i][1]) / 2:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	x = r - l
	print('YES' if l > x else 'NO')


import sys, os, io

def rs():
	return sys.stdin.readline().rstrip()

def ri():
	return int(sys.stdin.readline())

def ria():
	return list(map(int, sys.stdin.readline().split()))

def ws(s):
	sys.stdout.write(s + '\n')

def wi(n):
	sys.stdout.write(str(n) + '\n')

def wia(a):
	sys.stdout.write(' '.join([str(x) for x in a]) + '\n')
import math, datetime, functools, itertools, operator, bisect, fractions, statistics
from collections import deque, defaultdict, OrderedDict, Counter
from fractions import Fraction
from decimal import Decimal
from sys import stdout
from heapq import heappush, heappop, heapify, _heapify_max, _heappop_max

def main():
	starttime = datetime.datetime.now()
	if os.path.exists('input.txt'):
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	tc = ri()
	for _ in range(tc):
		(l, r) = ria()
		a = r + 1
		z = l % a
		if z >= math.ceil(a / 2):
			print('YES')
		else:
			print('NO')
	endtime = datetime.datetime.now()
	time = (endtime - starttime).total_seconds() * 1000
	if os.path.exists('input.txt'):
		print('Time:', time, 'ms')

class FastReader(io.IOBase):
	newlines = 0

	def __init__(self, fd, chunk_size=1024 * 8):
		self._fd = fd
		self._chunk_size = chunk_size
		self.buffer = io.BytesIO()

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self, size=-1):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size if size == -1 else size))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

class FastWriter(io.IOBase):

	def __init__(self, fd):
		self._fd = fd
		self.buffer = io.BytesIO()
		self.write = self.buffer.write

	def flush(self):
		os.write(self._fd, self.buffer.getvalue())
		(self.buffer.truncate(0), self.buffer.seek(0))

class FastStdin(io.IOBase):

	def __init__(self, fd=0):
		self.buffer = FastReader(fd)
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

class FastStdout(io.IOBase):

	def __init__(self, fd=1):
		self.buffer = FastWriter(fd)
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.flush = self.buffer.flush
sys.stdin = FastStdin()
sys.stdout = FastStdout()
main()


from __future__ import division, print_function
from fractions import Fraction
import sys
import os
from io import BytesIO, IOBase
from functools import cmp_to_key
from heapq import *
from math import gcd, factorial, floor, ceil
from copy import deepcopy
from collections import deque
from bisect import bisect_left as bl
from bisect import bisect_right as br
from bisect import bisect
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
				continue
			stack.pop()
			if not stack:
				break
			to = stack[-1].send(to)
		return to
	return wrapped_func

def inp():
	return sys.stdin.readline().rstrip('\r\n')

def out(var):
	sys.stdout.write(str(var))

def lis():
	return list(map(int, inp().split()))

def stringlis():
	return list(map(str, inp().split()))

def sep():
	return map(int, inp().split())

def strsep():
	return map(str, inp().split())

def zerolist(n):
	return [0] * n

def nextline():
	out('\n')

def testcase(t):
	for pp in range(t):
		solve(pp)

def printlist(a):
	for p in range(0, len(a)):
		out(str(a[p]) + ' ')

def google(p):
	print('Case #' + str(p) + ': ', end='')

def lcm(a, b):
	return a * b // gcd(a, b)

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def ncr(n, r):
	return factorial(n) // (factorial(r) * factorial(max(n - r, 1)))

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	i = 5
	while i * i <= n:
		if n % i == 0 or n % (i + 2) == 0:
			return False
		i = i + 6
	return True
inf = pow(10, 20)
mod = 10 ** 9 + 7

def solve(case):
	(l, r) = sep()
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')
testcase(int(inp()))


t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(l, r) = [int(i) for i in input().split()]
	if l / (r + 1) >= 0.5:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(L, R) = map(int, input().split())
	print('YES' if 2 * L >= R + 1 else 'NO')


for _ in range(int(input())):
	(a, b) = list(map(int, input().split()))
	print('YES') if 2 * a > b else print('NO')


N = int(input())
for i in range(N):
	(a, b) = map(int, input().split())
	if a >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


def solve():
	(l, r) = map(int, input().split())
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')
for _ in range(int(input())):
	solve()


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	a = r + 1
	if l % a >= a / 2 and r % a >= a / 2:
		print('YES')
	else:
		print('NO')


t = int(input())
while t:
	t += -1
	(l, r) = map(int, input().split())
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


testCases = int(input())
answers = []
for i in range(1, testCases + 1):
	input1 = list(map(int, input().split(' ')))
	a = input1[0]
	b = input1[1]
	if 2 * a > b:
		answers.append('YES')
	else:
		answers.append('NO')
for i in answers:
	print(i)


n = int(input())
for i in range(n):
	(l, r) = map(int, input().split())
	a = l * 2
	print('YES' if r < a else 'NO')


import sys
max_int = 1000000001
min_int = -max_int
t = int(input())
for _t in range(t):
	(l, r) = map(int, sys.stdin.readline().split())
	print('YES' if (r + 1) / 2 <= l else 'NO')


n = int(input())
while n > 0:
	(l, r) = map(int, input().split())
	if l >= (r + 1) / 2 or (l - 1) * 2 >= r:
		print('YES')
	else:
		print('NO')
	n -= 1


t = int(input())
while t:
	t -= 1
	lst = list(map(int, input().split()))
	if lst[1] / 2 >= lst[0]:
		print('NO')
	else:
		print('YES')


cases = int(input())
for t in range(cases):
	(l, r) = list(map(int, input().split()))
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


import math
t = int(input())
while t != 0:
	(l, r) = map(int, input().split())
	p = (l + r) // 2
	q = math.ceil((l + r) / 2)
	if l * 2 <= r:
		print('NO')
	else:
		print('YES')
	t -= 1


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	if r / l < 2:
		print('YES')
	else:
		print('NO')


for i in range(int(input())):
	(l, r) = map(int, input().split())
	we_want_minimum = r + 1
	print('YES' if l >= (r + 1) / 2 else 'NO')


a = int(input())
v = list()
for i in range(a):
	(l, r) = map(int, input().split())
	if r - l < l:
		v.append(1)
	else:
		v.append(0)
for i in range(a):
	if v[i] == 1:
		print('YES')
	else:
		print('NO')


import sys
input = sys.stdin.readline
ins = lambda : input().rstrip()
ini = lambda : int(input().rstrip())
inm = lambda : map(int, input().rstrip().split())
inl = lambda : list(map(int, input().split()))
out = lambda x, s='\n': print(s.join(map(str, x)))
t = ini()
for _ in range(t):
	(l, r) = inm()
	print('YES' if l * 2 > r else 'NO')


import math
for _ in range(int(input())):
	(n, m) = map(int, input().split())
	if m % (m + 1) >= (m + 1) / 2 and n % (m + 1) >= (m + 1) / 2:
		print('YES')
	else:
		print('NO')


def solve():
	(l, r) = [int(x) for x in input().split()]
	if l > r // 2:
		print('YES')
	else:
		print('NO')
t = int(input())
for i in range(t):
	solve()


from sys import stdin
rl = stdin.readline

def main(l, r):
	a = r + 1
	print('YES' if l >= a / 2 else 'NO')
t = int(rl())
cases = [list(map(int, rl().split())) for _ in range(t)]
for (l, r) in cases:
	main(l, r)


def calc(l, r):
	a = r + 1
	if l % a >= a / 2 and r % a >= a / 2:
		return 'YES'
	return 'NO'
t = int(input())
for i in range(t):
	(l, r) = list(map(int, input().split()))
	print(calc(l, r))


import sys

def inp():
	return int(input())

def inps():
	return input().rstrip()

def inpl():
	return list(map(int, input().split()))

def inpls():
	return list(map(str, input().split()))
t = inp()
for _ in range(t):
	(a, b) = inpl()
	if b >= 2 * a:
		print('NO')
	else:
		print('YES')


t = int(input())
for i in range(t):
	line = list(map(int, input().split()))
	(l, r) = (line[0], line[1])
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


t = int(input())
for i in range(t):
	(a, b) = input().strip().split(' ')
	(a, b) = [int(a), int(b)]
	k = (b + 1) // 2
	if (b + 1) % 2:
		k += 1
	if a >= k:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline()

def RL():
	return map(int, sys.stdin.readline().split())

def RLL():
	return list(map(int, sys.stdin.readline().split()))

def N():
	return int(input())

def print_list(l):
	print(' '.join(map(str, l)))
for _ in range(N()):
	(l, r) = RL()
	print('YES' if r < l * 2 else 'NO')


import sys, math
import io, os
from bisect import bisect_left as bl, bisect_right as br, insort
from heapq import heapify, heappush, heappop
from collections import defaultdict as dd, deque, Counter
from itertools import permutations, combinations

def data():
	return sys.stdin.readline().strip()

def mdata():
	return list(map(int, data().split()))

def outl(var):
	sys.stdout.write(' '.join(map(str, var)) + '\n')

def out(var):
	sys.stdout.write(str(var) + '\n')
INF = 10 ** 9
mod = int(1000000000.0) + 7
for t in range(int(data())):
	(l, r) = mdata()
	if l >= (r + 1) / 2:
		out('YES')
	else:
		out('NO')


import sys
import math
from functools import reduce
import bisect

def getN():
	return int(input())

def getNM():
	return map(int, input().split())

def getList():
	return list(map(int, input().split()))

def input():
	return sys.stdin.readline().rstrip()

def index(a, x):
	i = bisect.bisect_left(a, x)
	if i != len(a) and a[i] == x:
		return i
	return False
for _ in range(getN()):
	(l, r) = getNM()
	for i in (l, r):
		if not i % (r + 1) >= (r + 1) / 2:
			print('NO')
			break
	else:
		print('YES')


from sys import stdin, stdout
from collections import deque
import bisect
R = lambda : stdin.readline().strip()
RL = lambda f=None: list(map(f, R().split(' '))) if f else list(R().split(' '))
output = lambda x: stdout.write(str(x) + '\n')
output_list = lambda x: output(' '.join(map(str, x)))
T = int(input())
for _ in range(T):
	(l, r) = RL(int)
	if (r + 1) / 2 <= l:
		print('YES')
	else:
		print('NO')


a = int(input())
for i in range(a):
	(b, c) = map(int, input().split())
	if c >= 2 * b:
		print('NO')
	else:
		print('YES')


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	rem = r + 1
	if rem & 1:
		md = rem // 2
		if l > md:
			print('YES')
		else:
			print('NO')
	else:
		md = rem // 2
		if l >= md:
			print('YES')
		else:
			print('NO')


n = int(input())
l = []
for i in range(n):
	M = list(map(int, input().split()))
	l += [M]
for i in range(n):
	a = 0
	if l[i][0] * 2 > l[i][1] and l[i][0] > 1:
		a = 1
	elif l[i][0] == l[i][1]:
		a = 1
	print(a * 'YES' + (1 - a) * 'NO')


for t in range(int(input())):
	(a, b) = list(map(int, input().split()))
	print(['NO', 'YES'][a * 2 - 1 >= b])


import sys
from collections import defaultdict as dc
from collections import Counter
from bisect import bisect_right
import math
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	x = r + 1
	if l >= math.ceil((r + 1) / 2):
		print('YES')
	else:
		print('NO')


import sys
import math
from collections import defaultdict, deque
input = sys.stdin.readline

def inar():
	return [int(el) for el in input().split()]

def main():
	t = int(input())
	for _ in range(t):
		(a, b) = inar()
		if b // 2 < a:
			print('YES')
		else:
			print('NO')
main()


import sys
tests = int(sys.stdin.readline())
for _ in range(tests):
	(l, r) = list(map(int, sys.stdin.readline().split()))
	pack_size = r + 1
	if l < pack_size / 2:
		print('NO')
	else:
		print('YES')


import sys
from collections import defaultdict
input = sys.stdin.readline
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if r - l + 1 <= (r + 1) // 2:
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout
import collections
import heapq
import itertools
import functools
import math
import operator
import string
ALPHABET = string.ascii_lowercase
DIGITS = string.digits

def read_line():
	return stdin.readline().strip()

def read_int():
	return int(read_line())

def read_arr():
	return read_line().split(' ')

def read_int_arr():
	return [int(x) for x in read_arr()]

def query_interactive(s):
	print(s)
	stdout.flush()

def solve():
	(l, r) = read_int_arr()
	if r >= 2 * l:
		print('NO')
	else:
		print('YES')

def main():
	T = 1
	T = read_int()
	for _ in range(T):
		solve()
main()


for i in range(int(input())):
	s = list(map(int, input().split()))
	if s[0] / s[1] > 0.5:
		print('YES')
	else:
		print('NO')


import sys
input = iter(sys.stdin.read().splitlines()).__next__

def solve(L, R):
	a = R + 1
	return L % a * 2 >= a and R % a * 2 >= a
TC = int(input())
for tc in range(TC):
	(L, R) = map(int, input().split())
	res = solve(L, R)
	print('YES' if res else 'NO')


def main():
	t = int(input())
	while t > 0:
		calc_cans()
		t -= 1

def calc_cans():
	data = list(map(int, input().split()))
	l = data[0]
	r = data[1]
	if l * 2 > r:
		print('YES')
	else:
		print('NO')
main()


t = int(input())
for i in range(t):
	(n, m) = map(int, input().split())
	if m >= 2 * n:
		print('NO')
	else:
		print('YES')


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	print('YNEOS'[0 if l >= (r + 1) / 2 else 1::2])


for _ in range(int(input())):
	arr = [int(_) for _ in input().split()]
	mx = arr[1] + 1
	if arr[0] % mx >= mx / 2:
		print('YES')
	else:
		print('NO')


import sys
import math, bisect
sys.setrecursionlimit(10 ** 6)
from itertools import groupby, accumulate
from heapq import heapify, heappop, heappush
from collections import deque, Counter, defaultdict

def I():
	return int(sys.stdin.readline())

def neo():
	return map(int, sys.stdin.readline().split())

def Neo():
	return list(map(int, sys.stdin.readline().split()))
for _ in range(I()):
	(l, r) = neo()
	if l >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


import bisect
import math
import sys
input = sys.stdin.readline

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())

def solution():
	t = inp()
	for _ in range(t):
		(l, r) = inlt()
		if r < 2 * l:
			print('YES')
		else:
			print('NO')
solution()


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	print('YNEOS'[r >= 2 * l::2])


from sys import stdin, stdout

def get_ints():
	return map(int, stdin.readline().split())
for _ in range(int(input())):
	(l, r) = get_ints()
	if l % (r + 1) >= (r + 1) / 2:
		stdout.write('YES\n')
	else:
		stdout.write('NO\n')


import sys

def main():
	t = Iint()
	for _ in range(t):
		(l, r) = Imap()
		if l * 2 > r:
			print('YES')
		else:
			print('NO')
en = enumerate
FIO = 10

def debug(*args, c=6):
	pass
	print('\x1b[3{}m'.format(c), *args, '\x1b[0m', file=sys.stderr)
BUFSIZE = 8 * 1024

def Istr():
	return input()

def Iint():
	return int(input())

def Ilist():
	return list(map(int, input().split()))

def Imap():
	return map(int, input().split())

def Plist(li, s=' '):
	print(s.join(map(str, li)))
if not FIO:
	if __name__ == '__main__':
		main()
		exit()
else:
	from io import BytesIO, IOBase
	import os

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))

def input():
	return sys.stdin.readline().rstrip('\r\n')
main()


t = int(input())
for i in range(t):
	(l, r) = map(int, input().split())
	d = r - l
	if d >= l:
		print('NO')
	else:
		print('YES')


import sys, os
from math import sqrt, gcd, ceil, log, floor
from bisect import bisect, bisect_left
from collections import defaultdict, Counter, deque
from heapq import heapify, heappush, heappop
input = sys.stdin.readline
read = lambda : list(map(int, input().strip().split()))
mod = 10 ** 9 + 7

def main():
	ans = ''
	for _ in range(int(input())):
		(l, r) = read()
		if l * 2 > r:
			ans += 'YES'
		else:
			ans += 'NO'
		ans += '\n'
	print(ans)
main()


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	found = False
	if l >= (r + 1) / 2:
		found = True
	if found == True:
		print('YES')
	else:
		print('NO')


t = int(input())
for j in range(t):
	(l, r) = map(int, input().split())
	status = 'NO'
	if l % (r + 1) >= (r + 1) / 2:
		status = 'YES'
	print(status)


n = int(input())
result = []
for i in range(n):
	(l, r) = list(map(int, input().split()))
	if r - l < l:
		result.append('YES')
	else:
		result.append('NO')
for i in result:
	print(i)


import sys
sys.setrecursionlimit(10 ** 5 + 5)
from collections import defaultdict as dft, deque

def ml():
	return list(map(int, input().split()))

def mp():
	return map(int, input().split())

def solve():
	(a, b) = mp()
	if a * 2 > b:
		print('YES')
	else:
		print('NO')
t = int(input())
for _ in range(t):
	solve()


def main():
	n = int(input())
	for _ in range(n):
		(l, r) = [int(word) for word in input().rstrip().split()]
		if 2 * l < r + 1:
			print('NO')
		else:
			print('YES')
main()


T = int(input())
for t in range(T):
	(l, r) = map(int, input().split())
	num = r + 1
	if l % num >= num / 2.0:
		print('YES')
	else:
		print('NO')


import sys, os.path
from collections import *
from heapq import *
from copy import *
import math
mod = 10 ** 9 + 7
read = lambda : map(int, input().split())
inf = float('inf')
if os.path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
for t in range(int(input())):
	(l, r) = read()
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout
(input, print) = (stdin.readline, stdout.write)

def read():
	return list(map(int, input().split()))

def solve():
	(l, r) = read()
	if 2 * l > r:
		print('YES\n')
	else:
		print('NO\n')

def main():
	[t] = read()
	for _ in range(t):
		solve()
	return 0
main()


for _ in range(int(input())):
	(l, r) = list(map(int, input().strip().split()))
	if r < l * 2:
		print('YES')
	else:
		print('NO')


t = int(input())
for you in range(t):
	l = input().split()
	r = int(l[1])
	l = int(l[0])
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


from sys import stdin
from collections import Counter
input = stdin.readline
t = int(input())
while t > 0:
	t -= 1
	(l, r) = map(int, input().split())
	print('YES' if r / 2 < l else 'NO')


import sys
t = int(input().strip())
for a0 in range(t):
	l = [int(i) for i in input().split()]
	c = l[0]
	a = l[1]
	if a >= 2 * c:
		print('NO')
	else:
		print('YES')


n = int(input())

def p(m, n):
	if m * 2 > n:
		return 'YES'
	else:
		return 'NO'
for i in range(n):
	(a, b) = map(int, input().split())
	print(p(a, b))


def E1():
	t = int(input())
	ans = []
	for _ in range(t):
		(l, r) = map(int, input().split())
		if 2 * l > r:
			ans.append('YES')
		else:
			ans.append('NO')
	for i in ans:
		print(i)
E1()


t = int(input())
while t > 0:
	t -= 1
	(a, b) = map(int, input().split())
	if a * 2 <= b:
		print('NO')
	else:
		print('YES')


T = int(input())
for i in range(T):
	(L, R) = list(map(int, input().split()))
	if (R + 1) / 2 <= L:
		print('YES')
	else:
		print('NO')


import math
t = int(int(input()))
for k1 in range(t):
	(l, r) = map(int, input().rstrip().split())
	g = max(l, r) + 1
	if l % g >= g / 2 and r % g >= g / 2:
		print('YES')
	else:
		print('NO')


tests = int(input())
for test in range(tests):
	(a, b) = map(int, input().split())
	if a * 2 > b:
		print('YES')
	else:
		print('NO')


for t in range(int(input())):
	(l, r) = [int(k) for k in input().split()]
	if r < l * 2:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	p = False
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


import sys
input = sys.stdin.readline

def solve():
	(l, r) = map(int, input().split())
	return 'YES' if r < 2 * l else 'NO'
for _ in range(int(input())):
	print(solve())


from math import floor
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


from collections import *
from heapq import *
import math
x = int(input())
for i in range(x):
	(a, b) = map(int, input().split())
	if b < 2 * a:
		print('YES')
	else:
		print('NO')


test_cases = int(input())
res = []
for test in range(test_cases):
	st = input()
	lst = st.split()
	l = int(lst[0])
	r = int(lst[1])
	if r < l * 2:
		res.append('YES')
	else:
		res.append('NO')
for value in res:
	print(value)


for s in [*open(0)][1:]:
	(l, r) = map(int, s.split())
	print('YNEOS'[r >= 2 * l::2])


from sys import stdin
input = stdin.readline
for i in range(int(input())):
	(x, y) = map(int, input().split())
	if x * 2 > y:
		print('YES')
	else:
		print('NO')


from math import ceil
t = int(input())
while t > 0:
	t = t - 1
	[l, r] = input().split()
	l = int(l)
	r = int(r)
	x = r + 1
	x = ceil(x / 2)
	if l >= x:
		print('YES')
	else:
		print('NO')


for i in range(100000):
	c = 0
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	z = r + 1
	if l % z >= z / 2:
		print('YES')
	else:
		print('NO')


t = int(input())
while t > 0:
	t -= 1
	(l, r) = [int(x) for x in input().split()]
	if 2 * l - r > 1 or 2 * l - r == 1:
		print('YES')
	else:
		print('NO')


for s in [*open(0)][1:]:
	(r, l) = map(int, s.split())
	a = max(r, l) + 1
	while True:
		if r % a != 0 and l % a != 0:
			if r % a >= a / 2 and l % a >= a / 2:
				print('YES')
				break
			else:
				print('NO')
				break
		else:
			a += 1


def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s)])

def invr():
	return map(int, input().split())
n = inp()
for i in range(n):
	l = inlt()
	if l[0] * 2 <= l[1]:
		print('NO')
	else:
		print('YES')


from sys import stdin
_input = stdin.readline
(_max, _range, _int) = (max, range, int)

def solution():
	n = _int(_input())
	for _ in _range(n):
		(l, r) = [_int(i) for i in _input().split()]
		maximal = l * 2
		if r < maximal:
			print('YES')
		else:
			print('NO')
solution()


for t in range(int(input())):
	(x, y) = map(int, input().split())
	if 2 * x > y:
		print('YES')
	else:
		print('NO')


import sys
from collections import defaultdict
from sys import maxsize

def ini():
	return int(sys.stdin.readline())

def inp():
	return map(int, sys.stdin.readline().strip().split())

def li():
	return list(map(int, sys.stdin.readline().strip().split()))
for _ in range(ini()):
	(a, b) = inp()
	if (b + 1) / 2 <= a % (b + 1):
		print('YES')
	else:
		print('NO')


for i in range(int(input())):
	(a, b) = map(int, input().split())
	if a / b > 0.5:
		print('YES')
	else:
		print('NO')


import sys, collections, math, itertools, random
INF = sys.maxsize

def get_ints():
	return map(int, sys.stdin.readline().strip().split())

def get_array():
	return list(map(int, sys.stdin.readline().strip().split()))

def input():
	return sys.stdin.readline().strip()
mod = 1000000007
for _ in range(int(input())):
	(l, r) = get_ints()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


t = int(input())
for i in range(0, t):
	(x, y) = map(int, input().split())
	z = max(x, y)
	w = min(x, y)
	z1 = z / 2
	if w > z1:
		print('YES')
	else:
		print('NO')


from math import ceil
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	x = r + 1
	if l >= ceil(x / 2):
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(a, b) = map(int, input().split())
	a2 = b + 1
	if a % a2 >= a2 / 2 and b % a2 >= a2 / 2:
		print('YES')
	else:
		print('NO')


T = int(input())
for _ in range(T):
	(n, m) = map(int, input().split())
	if m >= 2 * n:
		print('NO')
	else:
		print('YES')


for _ in range(int(input())):
	(mi, ma) = map(int, input().split())
	if mi + int(mi / 1.5) / 2 > ma:
		print('YES')
	elif mi * 2 > ma:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(a, b) = map(int, input().split())
	if a == b:
		print('YES')
	elif b % a == 0 or b >= a * 2:
		print('NO')
	else:
		print('YES')


t = int(input())
arr = []
for _ in range(t):
	arr.append(list(map(int, input().split())))
for (l, r) in arr:
	if 2 * l > r:
		print('YES')
		continue
	print('NO')


from sys import stdin, stdout
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	ans = r + 1
	if l % ans >= ans / 2:
		print('YES')
	else:
		print('NO')


import os
from heapq import heapify, heappop, heappush
import sys
import math
import operator
import bisect
from collections import defaultdict
from io import BytesIO, IOBase
sys.setrecursionlimit(10 ** 5)

def inpt():
	return [int(k) for k in input().split()]

def main():
	for _ in range(int(input())):
		(a, b) = inpt()
		if b // 2 < a:
			print('YES')
		else:
			print('NO')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


import time, math as mt, bisect as bs, sys
from sys import stdin, stdout
from collections import deque
from fractions import Fraction
from collections import Counter
from collections import OrderedDict
pi = 3.141592653589793

def II():
	return int(stdin.readline())

def IP():
	return map(int, stdin.readline().split())

def L():
	return list(map(int, stdin.readline().split()))

def P(x):
	return stdout.write(str(x) + '\n')

def PI(x, y):
	return stdout.write(str(x) + ' ' + str(y) + '\n')

def lcm(a, b):
	return a * b // gcd(a, b)

def gcd(a, b):
	if a == 0:
		return b
	elif b == 0:
		return a
	if a > b:
		return gcd(a % b, b)
	else:
		return gcd(a, b % a)

def bfs(adj, v):
	visited = [False] * (v + 1)
	q = deque()
	while q:
		pass

def sieve():
	li = [True] * (2 * 10 ** 5 + 5)
	(li[0], li[1]) = (False, False)
	for i in range(2, len(li), 1):
		if li[i] == True:
			for j in range(i * i, len(li), i):
				li[j] = False
	prime = []
	for i in range(2 * 10 ** 5 + 5):
		if li[i] == True:
			prime.append(i)
	return prime

def setBit(n):
	count = 0
	while n != 0:
		n = n & n - 1
		count += 1
	return count
mx = 10 ** 7
spf = [mx] * (mx + 1)

def SPF():
	spf[1] = 1
	for i in range(2, mx + 1):
		if spf[i] == mx:
			spf[i] = i
			for j in range(i * i, mx + 1, i):
				if i < spf[j]:
					spf[j] = i
	return

def readTree(n, e):
	adj = [set() for i in range(n + 1)]
	for i in range(e):
		(u1, u2) = IP()
		adj[u1].add(u2)
	return adj
mod = 10 ** 9 + 7

def solve():
	(l, r) = IP()
	x = 2 * l
	y = r // 2 + 1
	if (l % x >= x / 2 and r % x >= x / 2) and x > r:
		print('YES')
		return
	if (l % y >= y / 2 and r % y >= y / 2) and y < l and (y * 2 > r):
		print('YES')
		return
	print('NO')
	return
t = II()
for i in range(t):
	solve()


t = int(input())
while t > 0:
	t -= 1
	(l, r) = input().split()
	l = int(l)
	r = int(r)
	if l + l >= r + 1:
		print('YES')
	else:
		print('NO')


import math
from collections import Counter, defaultdict, deque

def f(n, m):
	if (m + 1) / 2 <= n:
		return 'YES'
	else:
		return 'NO'
t = int(input())
result = []
for i in range(t):
	(n, m) = list(map(int, input().split()))
	result.append(f(n, m))
for i in range(t):
	print(result[i])


t = int(input())
for i in range(t):
	nums = [int(x) for x in input().split()]
	if nums[0] <= nums[1] / 2:
		print('NO')
	else:
		print('YES')


n = int(input())
for i in range(n):
	lis = list(map(int, input().split()))
	lis.sort()
	if lis[0] * 2 > lis[1]:
		print('YES')
	else:
		print('NO')


t = int(input())
a = []
for i in range(t):
	(l, r) = map(int, input().split())
	if l * 2 - 1 >= r:
		a.append('YES')
	else:
		a.append('NO')
for i in range(t):
	print(a[i])


f = int(input())
for i10 in range(f):
	(l, r) = map(int, input().split())
	if r < l * 2:
		print('YES')
	else:
		print('NO')


import sys
tc = int(sys.stdin.readline())
for _ in range(tc):
	(a, b) = map(int, sys.stdin.readline().split())
	if a % (b + 1) >= (b + 1) / 2 and b % (b + 1) >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


import sys as _sys

def main():
	t = int(input())
	for i_t in range(t):
		(l, r) = _read_ints()
		a = r + 1
		if l >= (a + 1) // 2:
			result = 'YES'
		else:
			result = 'NO'
		print(result)

def _read_line():
	result = _sys.stdin.readline()
	assert result[-1] == '\n'
	return result[:-1]

def _read_ints():
	return map(int, _read_line().split())
main()


import math
for x in range(int(input())):
	(h, m) = list(map(int, input().split()))
	if h >= math.ceil((m + 1) / 2):
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(a, b) = [int(i) for i in input().split()]
	print('YES' if b // 2 < a else 'NO')


import sys
import math
from collections import Counter
from collections import OrderedDict
from collections import defaultdict
from functools import reduce
sys.setrecursionlimit(10 ** 6)

def inputt():
	return sys.stdin.readline().strip()

def printt(n):
	sys.stdout.write(str(n) + '\n')

def listt():
	return [int(i) for i in inputt().split()]

def gcd(a, b):
	return math.gcd(a, b)

def lcm(a, b):
	return a * b // gcd(a, b)

def factors(n):
	step = 2 if n % 2 else 1
	return set(reduce(list.__add__, ([i, n // i] for i in range(1, int(math.sqrt(n)) + 1, step) if n % i == 0)))

def comb(n, k):
	factn = math.factorial(n)
	factk = math.factorial(k)
	fact = math.factorial(n - k)
	ans = factn // (factk * fact)
	return ans

def is_prime(n):
	if n <= 1:
		return False
	if n == 2:
		return True
	if n > 2 and n % 2 == 0:
		return False
	max_div = math.floor(math.sqrt(n))
	for i in range(3, 1 + max_div, 2):
		if n % i == 0:
			return False
	return True

def maxpower(n, x):
	B_max = int(math.log(n, x)) + 1
	return B_max
t = int(inputt())
for _ in range(t):
	(n, k) = map(int, inputt().split())
	a = k + 1
	if n % a >= a / 2 and k % a >= a / 2:
		print('YES')
	else:
		printt('NO')


a = int(input())
res = 0
while res < a:
	(n, m) = map(int, input().split())
	if 2 * n > m:
		print('YES')
	else:
		print('NO')
	res += 1


import sys
from collections import deque
from copy import *
from itertools import permutations as prm, product

def eprint(*args):
	print(*args, file=sys.stderr)
zz = 1
if zz:
	input = sys.stdin.readline
else:
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('all.txt', 'w')
di = [[-1, 0], [1, 0], [0, 1], [0, -1]]

def string(s):
	return ''.join(s)

def fori(n):
	return [fi() for i in range(n)]

def inc(d, c, x=1):
	d[c] = d[c] + x if c in d else x

def bo(i):
	return ord(i) - ord('A')

def li():
	return [int(xx) for xx in input().split()]

def fli():
	return [float(x) for x in input().split()]

def comp(a, b):
	if a > b:
		return 2
	return 2 if a == b else 0

def gi():
	return [xx for xx in input().split()]

def cil(n, m):
	return n // m + int(n % m > 0)

def fi():
	return int(input())

def pro(a):
	return reduce(lambda a, b: a * b, a)

def swap(a, i, j):
	(a[i], a[j]) = (a[j], a[i])

def si():
	return list(input().rstrip())

def mi():
	return map(int, input().split())

def gh():
	sys.stdout.flush()

def isvalid(i, j, n, m):
	return 0 <= i < n and 0 <= j < m

def bo(i):
	return ord(i) - ord('a')

def graph(n, m):
	for i in range(m):
		(x, y) = mi()
		a[x].append(y)
		a[y].append(x)
t = fi()
while t > 0:
	t -= 1
	(l, r) = mi()
	print('YES' if 2 * l > r else 'NO')


from math import *
sInt = lambda : int(input())
mInt = lambda : map(int, input().split())
lInt = lambda : list(map(int, input().split()))
t = sInt()
for _ in range(t):
	(l, r) = mInt()
	if l <= r // 2:
		print('NO')
	else:
		print('YES')


from math import *
from collections import Counter, defaultdict
I = lambda : int(input())
M = lambda : map(int, input().split())
LI = lambda : list(map(int, input().split()))
for _ in range(I()):
	(a, b) = M()
	if 2 * a > b:
		print('YES')
	else:
		print('NO')


import sys, math, itertools, collections, copy
input = sys.stdin.readline

def solve():
	(l, r) = map(int, input().split())
	if l * 2 > r:
		print('YES')
	else:
		print('NO')
for _ in range(int(input())):
	solve()


import sys
rawdata = sys.stdin.read()
data = list((n for n in rawdata.split()))
x = int(data[0]) * 2
for i in range(1, x, 2):
	if int(data[i + 1]) // 2 < int(data[i]):
		print('YES')
	else:
		print('NO')


import sys
for _ in range(int(sys.stdin.readline())):
	a = list(map(int, sys.stdin.readline().strip().split(' ')))
	if a[1] < 2 * a[0]:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(l, r) = (int(x) for x in input().split())
	a = 2 * l
	if a <= r:
		print('NO')
	else:
		print('YES')


t = int(input())
for q in range(t):
	(l, r) = [int(x) for x in input().split()]
	resp = 'NO'
	if 2 * l >= r + 1:
		resp = 'YES'
	print(resp)


for t in range(int(input())):
	(l, r) = map(int, input().split())
	a = float(r + 1)
	num = float(a / 2)
	if l >= num:
		print('YES')
	else:
		print('NO')


test_cases = int(input())
for test_case in range(test_cases):
	(l, r) = list(map(int, input().split()))
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout

def II():
	return int(stdin.readline())

def MI():
	return map(int, stdin.readline().split())
yes = 'YES\n'
no = 'NO\n'

def solve():
	(l, r) = MI()
	if l + l > r:
		stdout.write(yes)
	else:
		stdout.write(no)
t = II()
for _ in range(t):
	solve()


ans = []
for _ in range(int(input())):
	(a, b) = list(map(int, input().split()))
	if a * 2 <= b:
		ans.append('NO')
	else:
		ans.append('YES')
print('\n'.join(ans))


n = int(input())
for k in range(n):
	(x, y) = map(int, input().split())
	if y < 2 * x:
		print('YES')
	else:
		print('NO')


from math import ceil

def solve(l, r):
	if l < ceil((r + 1) / 2):
		return False
	return True
for _ in range(int(input())):
	(l, r) = list(map(int, input().split()))
	if solve(l, r):
		print('YES')
	else:
		print('NO')


T = int(input())
for i in range(T):
	(l, r) = map(int, input().split())
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


from __future__ import print_function
from collections import Counter, OrderedDict
from itertools import permutations as perm
from collections import deque
from sys import stdin
from bisect import *
from heapq import *
import math
g = lambda : stdin.readline().strip()
gl = lambda : g().split()
gil = lambda : [int(var) for var in gl()]
gfl = lambda : [float(var) for var in gl()]
gcl = lambda : list(g())
gbs = lambda : [int(var) for var in g()]
mod = int(1000000000.0) + 7
inf = float('inf')
(t,) = gil()
for _ in range(t):
	(l, r) = gil()
	print('YES' if 2 * l > r else 'NO')


for i in range(int(input())):
	(l, r) = map(int, input().split())
	if l <= abs(l - r):
		print('NO')
	else:
		print('YES')


def f(n, m):
	res = 'YES'
	if (n + 1) % 2 == 0:
		if m < (n + 1) // 2:
			res = 'NO'
	elif m <= (n + 1) // 2:
		res = 'NO'
	print(res)
for i in range(int(input())):
	(m, n) = map(int, input().split())
	f(n, m)


R = lambda : map(int, input().split())
for _ in range(int(input())):
	(l, r) = R()
	print(['NO', 'YES'][r < 2 * l])


try:
	for _ in range(int(input())):
		(a, b) = map(int, input().split())
		if a > b / 2:
			print('YES')
		else:
			print('NO')
except:
	pass


t = int(input())
for _ in range(t):
	a = list(map(int, input().split()))
	a.sort()
	if (a[-1] + 1) / 2 <= a[0]:
		print('YES')
	else:
		print('NO')


import sys
t = int(sys.stdin.readline().rstrip())
for _ in range(t):
	(l, r) = list(map(int, sys.stdin.readline().strip().split(' ')))
	a = r + 1
	a2 = (r + 1) / 2
	q = l
	if q >= a2:
		print('YES')
	else:
		print('NO')


def solve():
	lst = input()
	lst = lst.split()
	for i in range(len(lst)):
		lst[i] = int(lst[i])
	if 2 * lst[0] > lst[1]:
		print('YES')
	else:
		print('NO')
t = int(input())
while t > 0:
	solve()
	t = t - 1


from sys import stdin
from math import ceil, floor
for _ in range(int(stdin.readline())):
	(l, r) = map(int, stdin.readline().split())
	diff = r - l
	mod = diff * 2
	if l >= (r + 1) / 2:
		print('YES')
	else:
		if l == 1:
			print('NO')
			continue
		tr = floor(2 * l / 3)
		if r % tr >= tr / 2 and r - l < tr:
			print('YES')
		else:
			print('NO')


def main(l, r):
	n = r // 2 + 1
	if n < l:
		return 'YES'
	for x in range(r, l * 2 + 1):
		if l % x >= l / 2 and r % x >= r / 2:
			return 'YES'
	return 'NO'
t = int(input())
for _ in range(t):
	(l, r) = [int(x) for x in input().split()]
	print(main(l, r))


t = int(input())
temp_arr = []
for i in range(t):
	can_list = list(map(int, input().split()))
	left_range = can_list[0]
	right_range = can_list[1]
	if right_range < 2 * left_range:
		temp_arr.append('YES')
	else:
		temp_arr.append('NO')
for j in temp_arr:
	print(j)


import math
import sys
import itertools
import fractions
wtf = sys.stdin.read()
wtf = wtf.strip().split('\n')
for t in wtf[1:]:
	(l, r) = map(int, t.split())
	print('NO' if r >= 2 * l else 'YES')


import io
import os
from collections import Counter, defaultdict, deque

def solve(L, R):
	A = R + 1
	if L >= (A + 1) // 2:
		return 'YES'
	return 'NO'
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
TC = int(input())
for tc in range(1, TC + 1):
	(L, R) = [int(x) for x in input().split()]
	ans = solve(L, R)
	print(ans)


T = int(input())
while T != 0:
	(l, r) = [int(i) for i in input().split()]
	if r / l < 2:
		print('YES')
	else:
		print('NO')
	T -= 1


for q in range(int(input())):
	(l, r) = map(int, input().split())
	print('YES' if l >= (r + 1) / 2 else 'NO')


from sys import stdin, stdout

def INI():
	return int(stdin.readline())

def INL():
	return [int(_) for _ in stdin.readline().split()]

def INS():
	return stdin.readline()

def MOD():
	return pow(10, 9) + 7

def OPS(ans):
	stdout.write(str(ans) + '\n')

def OPL(ans):
	[stdout.write(str(_) + ' ') for _ in ans]
	stdout.write('\n')

def __starting_point():
	for _ in range(INI()):
		(L, R) = INL()
		if R // 2 < L:
			OPS('YES')
		else:
			OPS('NO')
__starting_point()


for i in range(int(input())):
	(l, r) = [int(w) for w in input().split()]
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


import os
import sys
from collections import *
from heapq import *
from bisect import *
from io import BytesIO, IOBase

def vsInput():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
ALPHA = 'abcdefghijklmnopqrstuvwxyz/'
M = 1000000007
EPS = 1e-06

def Ceil(a, b):
	return a // b + int(a % b > 0)

def value():
	return tuple(map(int, input().split()))

def array():
	return [int(i) for i in input().split()]

def Int():
	return int(input())

def Str():
	return input()

def arrayS():
	return [i for i in input().split()]
for _ in range(Int()):
	(l, r) = value()
	if r < l * 2:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	if n * 2 > k:
		print('YES')
	else:
		print('NO')


import sys, math
input = sys.stdin.readline
t = int(input())
for rr in range(t):
	(l, r) = map(int, input().split())
	ans = r + 1
	if l % ans < ans / 2 or r % ans < ans / 2:
		print('NO')
	else:
		print('YES')


from bisect import bisect_left as bl
from bisect import bisect_right as br
from heapq import heappush, heappop
import math
from collections import *
from functools import reduce, cmp_to_key, lru_cache
import io, os
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
M = mod = 10 ** 9 + 7

def factors(n):
	return sorted(set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0))))

def inv_mod(n):
	return pow(n, mod - 2, mod)

def li():
	return [int(i) for i in input().rstrip().split()]

def st():
	return str(input().rstrip())[2:-1]

def val():
	return int(input().rstrip())

def li2():
	return [str(i)[2:-1] for i in input().rstrip().split()]

def li3():
	return [int(i) for i in st()]
for _ in range(val()):
	(l, r) = li()
	print('YES' if r + 1 <= 2 * l else 'NO')


t = int(input())
for a in range(t):
	my_list = list(map(int, input().strip().split()))
	l = my_list[0]
	r = my_list[1]
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


def solve(l, r):
	if r // 2 < l:
		return 'YES'
	else:
		return 'NO'
t = int(input())
while t:
	(l, r) = map(int, input().split())
	print(solve(l, r))
	t -= 1


import math
t = int(input())
for i in range(t):
	(l, r) = list(map(int, input().split()))
	if l >= (r + 1) / 2 and r >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


def test(l, r):
	for a in range(1, r + 2):
		for x in range(l, r + 1):
			if x % a < a / 2:
				break
		else:
			return True
	return False

def solve(l, r):
	if l % (r + 1) >= (r + 1) / 2:
		return True
	return False

def test2():
	for l in range(1, 1000):
		for r in range(l, 1000):
			print(l, r)
			assert test(l, r) == solve(l, r)

def test3(t):
	test_answers = [False for _ in range(t)]
	for i in range(t):
		(l, r) = map(int, input().split())
		test_answers[i] = test(l, r)
	print(test_answers)

def main():
	t = int(input())
	answers = [False for _ in range(t)]
	for i in range(t):
		(l, r) = map(int, input().split())
		answers[i] = solve(l, r)
	for answer in answers:
		if answer:
			print('YES')
		else:
			print('NO')
main()


for __ in range(int(input())):
	(a, b) = list(map(int, input().split()))
	x = b + 1
	if a % x >= x / 2:
		print('YES')
	else:
		print('NO')


m = int(input())
l = []
for i in range(m):
	(a, b) = map(int, input().split())
	if (b + 1) / 2 <= a % (b + 1) and (b + 1) / 2 <= b % (b + 1):
		l.append('YES')
	else:
		l.append('NO')
for i in l:
	print(i)


mod = 10 ** 9 + 7

def solve():
	(l, r) = map(int, input().split())
	k = r + 1
	print('YES' if l % k >= k / 2 else 'NO')
t = 1
t = int(input())
while t > 0:
	solve()
	t -= 1


t = int(input())
while t > 0:
	a = list(map(int, input().split()))
	if a[1] // a[0] > 1:
		print('NO')
	else:
		print('YES')
	t -= 1


import sys, collections
input = sys.stdin.readline
t = int(input())
while t:
	t -= 1
	vals = list(map(int, input().split()))
	if vals == [1, 2]:
		print('NO')
		continue
	x = vals[0] * 2
	if vals[-1] < x:
		print('YES')
		continue
	print('NO')


from sys import stdout, stdin
from collections import defaultdict, deque
import math
t = int(stdin.readline())
for _ in range(t):
	l = list(map(int, stdin.readline().split()))
	if 2 * l[0] <= l[1]:
		print('NO')
	else:
		print('YES')


import sys
input = sys.stdin.readline

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())

def isPrime(num):
	if num > 1:
		for i in range(2, num):
			if num % i == 0:
				return False
		return True
	else:
		return False

def calcSumPrime(n):
	s = 1
	for i in range(1, n + 1):
		if isPrime(i) == True:
			s = s * i
	return s

def main():
	t = inp()
	while t > 0:
		t -= 1
		(l, r) = invr()
		if r < 2 * l:
			print('YES')
		else:
			print('NO')
input = sys.stdin.readline
main()


for tc in range(int(input())):
	(l, r) = map(int, input().split(' '))
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


import math
test = int(input())
for t in range(test):
	tt = 0
	pp = 0
	cc = ''
	ss = ''
	dd = 1
	cnttt = 0
	damn = 1e+18
	ammo = 'FULL'
	(a, b) = map(int, input().split())
	aa = a % (b + 1)
	bb = b % (b + 1)
	if aa >= (b + 1) / 2 and bb >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


T = int(input().strip())
for _ in range(T):
	(l, r) = map(int, input().strip().split())
	a = l * 2
	ans = 'YES' if r < a else 'NO'
	print(ans)


from sys import maxsize, stdout, stdin, stderr
mod = int(1000000000.0 + 7)
import re

def tup():
	return map(int, stdin.readline().split())

def I():
	return int(stdin.readline())

def lint():
	return [int(x) for x in stdin.readline().split()]

def S():
	return input().strip()

def grid(r, c):
	return [lint() for i in range(r)]

def debug(*args, c=6):
	print('\x1b[3{}m'.format(c), *args, '\x1b[0m', file=stderr)
from math import log2, sqrt
for _ in range(I()):
	(a, b) = tup()
	if b / 2 < a:
		print('YES')
	else:
		print('NO')


def zip_sorted(a, b):
	(a, b) = zip(*sorted(zip(a, b)))
	sorted(zip(a, b), key=lambda x: x[1])
	return (a, b)
import sys
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
S = lambda : list(map(str, input().split()))
(t,) = I()
for t1 in range(t):
	(l, r) = I()
	if l % (r + 1) >= float((r + 1) / 2):
		print('YES')
	else:
		print('NO')


import sys, os, io
input = sys.stdin.readline
T = int(input())
ans = [0] * T
for t in range(T):
	(N, M) = map(int, input().split())
	if M < 2 * N:
		ans[t] = 'YES'
	else:
		ans[t] = 'NO'
print(*ans, sep='\n')


import sys, io, os, time
from collections import defaultdict
from collections import Counter
from collections import deque
from itertools import combinations
from itertools import permutations
import bisect, math, heapq
alphabet = 'abcdefghijklmnopqrstuvwxyz'
input = sys.stdin.readline
for ii in range(int(input())):
	(l, r) = map(int, input().split())
	a = r + 1
	if l % a >= a / 2 and r % a >= a / 2:
		print('YES')
	else:
		print('NO')


import sys
import math
from collections import Counter, defaultdict
LI = lambda : list(map(int, input().split()))
MAP = lambda : map(int, input().split())
IN = lambda : int(input())
S = lambda : input()

def case():
	(l, r) = MAP()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')
for _ in range(IN()):
	case()


from sys import stdin, stdout
from math import factorial as f
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if l * 2 <= r:
		print('NO')
	else:
		print('YES')


import sys
reader = (s.rstrip() for s in sys.stdin)
input = reader.__next__

def gift():
	for _ in range(t):
		(l, r) = list(map(int, input().split()))
		if r / l < 2:
			yield 'YES'
		else:
			yield 'NO'
t = int(input())
ans = gift()
print(*ans, sep='\n')


t = int(input())
for i in range(t):
	n = [int(i) for i in input().split()]
	l = n[0]
	r = n[1]
	if l * 2 > r:
		print('YES')
	elif l == r:
		print('YES')
	else:
		print('NO')


def read_int():
	return int(input())

def read_ints():
	return map(int, input().split(' '))
t = read_int()
for case_num in range(t):
	(l, r) = read_ints()
	print('YES' if l * 2 > r else 'NO')


t = int(input())
for i in range(t):
	(a, b) = list(map(int, input().split()))
	x = a % (b + 1)
	y = (b + 1) / 2
	if x >= y:
		print('YES')
	else:
		print('NO')


def count(array):
	mine = array[0]
	maxe = array[1]
	if 2 * mine <= maxe:
		return 'NO'
	else:
		return 'YES'
test_cases = int(input())
for i in range(test_cases):
	array = list(map(int, input().split()))
	print(count(array))


from math import *
from bisect import *
from collections import *
from random import *
from decimal import *
from itertools import *
from heapq import *
import sys
input = sys.stdin.readline

def inp():
	return int(input())

def st():
	return input().rstrip('\n')

def lis():
	return list(map(int, input().split()))

def ma():
	return map(int, input().split())
t = inp()
while t:
	t -= 1
	(a, b) = ma()
	if b >= 2 * a:
		print('NO')
	else:
		print('YES')


(T,) = map(int, input().split())
for _ in range(T):
	(l, r) = map(int, input().split())
	a = r + 1
	if 2 * l >= a:
		print('YES')
		continue
	a = l * 2 // 3
	if not a:
		print('NO')
		continue
	if l // a != r // a:
		print('NO')
		continue
	print('YES')


import sys
import os
import math
import copy
from bisect import bisect
from io import BytesIO, IOBase
from math import sqrt, floor, factorial, gcd, log, ceil
from collections import deque, Counter, defaultdict
from itertools import permutations, combinations, accumulate

def Int():
	return int(sys.stdin.readline())

def Mint():
	return map(int, sys.stdin.readline().split())

def Lstr():
	return list(sys.stdin.readline().strip())

def Str():
	return sys.stdin.readline().strip()

def Mstr():
	return map(str, sys.stdin.readline().strip().split())

def List():
	return list(map(int, sys.stdin.readline().split()))

def Hash():
	return dict()

def Mod():
	return 1000000007

def Mat2x2(n):
	return [List() for _ in range(n)]

def Lcm(x, y):
	return x * y // gcd(x, y)

def dtob(n):
	return bin(n).replace('0b', '')

def btod(n):
	return int(n, 2)

def watch(x):
	return print(x)

def common(l1, l2):
	return set(l1).intersection(l2)

def Most_frequent(list):
	return max(set(list), key=list.count)

def solution():
	for _ in range(Int()):
		(l, r) = Mint()
		m = abs(r - l)
		if abs(r - l) >= l:
			print('NO')
		else:
			print('YES')
solution()


import os, sys
from collections import defaultdict, Counter, deque
from io import BytesIO, IOBase
from math import gcd

def main():
	for i in range(int(input())):
		(a, b) = map(int, input().split())
		if a > b // 2:
			print('YES')
		else:
			print('NO')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


for _ in range(int(input().strip(' '))):
	(l, r) = sorted([int(x) for x in input().split(' ')])
	if l >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


from collections import defaultdict as dd
import sys
input = sys.stdin.readline
t = int(input())
while t:
	(n, m) = map(int, input().split())
	if (m + 1) / 2 <= n:
		print('YES')
	else:
		print('NO')
	t -= 1


def marketer(a, b):
	return b < 2 * a
for _ in range(int(input())):
	(a, b) = map(int, input().split())
	print('YES' if marketer(a, b) else 'NO')


for tc in range(int(input())):
	(left, r) = map(int, input().split())
	if r + 1 <= 2 * left:
		print('YES')
		continue
	print('NO')


import math
from collections import defaultdict

class Solution:

	def __init__(self):
		pass

	def run(self):
		(l, r) = [int(x) for x in input().split()]
		if r < l * 2:
			return 'YES'
		else:
			return 'NO'
t = int(input())
s = Solution()
for i in range(t):
	print(s.run())


T = int(input())
for i in range(T):
	(l, r) = (int(s) for s in input().split())
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


import sys
from math import gcd, sqrt, ceil, log2
from collections import defaultdict, Counter, deque
from bisect import bisect_left, bisect_right
import math
sys.setrecursionlimit(2 * 10 ** 5 + 10)
import heapq
from itertools import permutations
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def get_sum(bit, i):
	s = 0
	i += 1
	while i > 0:
		s += bit[i]
		i -= i & -i
	return s

def update(bit, n, i, v):
	i += 1
	while i <= n:
		bit[i] += v
		i += i & -i

def modInverse(b, m):
	g = math.gcd(b, m)
	if g != 1:
		return -1
	else:
		return pow(b, m - 2, m)

def primeFactors(n):
	sa = set()
	sa.add(n)
	while n % 2 == 0:
		sa.add(2)
		n = n // 2
	for i in range(3, int(math.sqrt(n)) + 1, 2):
		while n % i == 0:
			sa.add(i)
			n = n // i
	return sa

def seive(n):
	pri = [True] * (n + 1)
	p = 2
	while p * p <= n:
		if pri[p] == True:
			for i in range(p * p, n + 1, p):
				pri[i] = False
		p += 1
	return pri

def check_prim(n):
	if n < 0:
		return False
	for i in range(2, int(sqrt(n)) + 1):
		if n % i == 0:
			return False
	return True

def getZarr(string, z):
	n = len(string)
	(l, r, k) = (0, 0, 0)
	for i in range(1, n):
		if i > r:
			(l, r) = (i, i)
			while r < n and string[r - l] == string[r]:
				r += 1
			z[i] = r - l
			r -= 1
		else:
			k = i - l
			if z[k] < r - i + 1:
				z[i] = z[k]
			else:
				l = i
				while r < n and string[r - l] == string[r]:
					r += 1
				z[i] = r - l
				r -= 1

def search(text, pattern):
	concat = pattern + '$' + text
	l = len(concat)
	z = [0] * l
	getZarr(concat, z)
	ha = []
	for i in range(l):
		if z[i] == len(pattern):
			ha.append(i - len(pattern) - 1)
	return ha

def mergeIntervals(arr):
	arr.sort(key=lambda x: x[0])
	m = []
	s = -10000
	max = -100000
	for i in range(len(arr)):
		a = arr[i]
		if a[0] > max:
			if i != 0:
				m.append([s, max])
			max = a[1]
			s = a[0]
		elif a[1] >= max:
			max = a[1]
	if max != -100000 and [s, max] not in m:
		m.append([s, max])
	return m

class SortedList:

	def __init__(self, iterable=[], _load=200):
		values = sorted(iterable)
		self._len = _len = len(values)
		self._load = _load
		self._lists = _lists = [values[i:i + _load] for i in range(0, _len, _load)]
		self._list_lens = [len(_list) for _list in _lists]
		self._mins = [_list[0] for _list in _lists]
		self._fen_tree = []
		self._rebuild = True

	def _fen_build(self):
		self._fen_tree[:] = self._list_lens
		_fen_tree = self._fen_tree
		for i in range(len(_fen_tree)):
			if i | i + 1 < len(_fen_tree):
				_fen_tree[i | i + 1] += _fen_tree[i]
		self._rebuild = False

	def _fen_update(self, index, value):
		if not self._rebuild:
			_fen_tree = self._fen_tree
			while index < len(_fen_tree):
				_fen_tree[index] += value
				index |= index + 1

	def _fen_query(self, end):
		if self._rebuild:
			self._fen_build()
		_fen_tree = self._fen_tree
		x = 0
		while end:
			x += _fen_tree[end - 1]
			end &= end - 1
		return x

	def _fen_findkth(self, k):
		_list_lens = self._list_lens
		if k < _list_lens[0]:
			return (0, k)
		if k >= self._len - _list_lens[-1]:
			return (len(_list_lens) - 1, k + _list_lens[-1] - self._len)
		if self._rebuild:
			self._fen_build()
		_fen_tree = self._fen_tree
		idx = -1
		for d in reversed(range(len(_fen_tree).bit_length())):
			right_idx = idx + (1 << d)
			if right_idx < len(_fen_tree) and k >= _fen_tree[right_idx]:
				idx = right_idx
				k -= _fen_tree[idx]
		return (idx + 1, k)

	def _delete(self, pos, idx):
		_lists = self._lists
		_mins = self._mins
		_list_lens = self._list_lens
		self._len -= 1
		self._fen_update(pos, -1)
		del _lists[pos][idx]
		_list_lens[pos] -= 1
		if _list_lens[pos]:
			_mins[pos] = _lists[pos][0]
		else:
			del _lists[pos]
			del _list_lens[pos]
			del _mins[pos]
			self._rebuild = True

	def _loc_left(self, value):
		if not self._len:
			return (0, 0)
		_lists = self._lists
		_mins = self._mins
		(lo, pos) = (-1, len(_lists) - 1)
		while lo + 1 < pos:
			mi = lo + pos >> 1
			if value <= _mins[mi]:
				pos = mi
			else:
				lo = mi
		if pos and value <= _lists[pos - 1][-1]:
			pos -= 1
		_list = _lists[pos]
		(lo, idx) = (-1, len(_list))
		while lo + 1 < idx:
			mi = lo + idx >> 1
			if value <= _list[mi]:
				idx = mi
			else:
				lo = mi
		return (pos, idx)

	def _loc_right(self, value):
		if not self._len:
			return (0, 0)
		_lists = self._lists
		_mins = self._mins
		(pos, hi) = (0, len(_lists))
		while pos + 1 < hi:
			mi = pos + hi >> 1
			if value < _mins[mi]:
				hi = mi
			else:
				pos = mi
		_list = _lists[pos]
		(lo, idx) = (-1, len(_list))
		while lo + 1 < idx:
			mi = lo + idx >> 1
			if value < _list[mi]:
				idx = mi
			else:
				lo = mi
		return (pos, idx)

	def add(self, value):
		_load = self._load
		_lists = self._lists
		_mins = self._mins
		_list_lens = self._list_lens
		self._len += 1
		if _lists:
			(pos, idx) = self._loc_right(value)
			self._fen_update(pos, 1)
			_list = _lists[pos]
			_list.insert(idx, value)
			_list_lens[pos] += 1
			_mins[pos] = _list[0]
			if _load + _load < len(_list):
				_lists.insert(pos + 1, _list[_load:])
				_list_lens.insert(pos + 1, len(_list) - _load)
				_mins.insert(pos + 1, _list[_load])
				_list_lens[pos] = _load
				del _list[_load:]
				self._rebuild = True
		else:
			_lists.append([value])
			_mins.append(value)
			_list_lens.append(1)
			self._rebuild = True

	def discard(self, value):
		_lists = self._lists
		if _lists:
			(pos, idx) = self._loc_right(value)
			if idx and _lists[pos][idx - 1] == value:
				self._delete(pos, idx - 1)

	def remove(self, value):
		_len = self._len
		self.discard(value)
		if _len == self._len:
			raise ValueError('{0!r} not in list'.format(value))

	def pop(self, index=-1):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		value = self._lists[pos][idx]
		self._delete(pos, idx)
		return value

	def bisect_left(self, value):
		(pos, idx) = self._loc_left(value)
		return self._fen_query(pos) + idx

	def bisect_right(self, value):
		(pos, idx) = self._loc_right(value)
		return self._fen_query(pos) + idx

	def count(self, value):
		return self.bisect_right(value) - self.bisect_left(value)

	def __len__(self):
		return self._len

	def __getitem__(self, index):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		return self._lists[pos][idx]

	def __delitem__(self, index):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		self._delete(pos, idx)

	def __contains__(self, value):
		_lists = self._lists
		if _lists:
			(pos, idx) = self._loc_left(value)
			return idx < len(_lists[pos]) and _lists[pos][idx] == value
		return False

	def __iter__(self):
		return (value for _list in self._lists for value in _list)

	def __reversed__(self):
		return (value for _list in reversed(self._lists) for value in reversed(_list))

	def __repr__(self):
		return 'SortedList({0})'.format(list(self))

def ncr(n, r, p):
	num = den = 1
	for i in range(r):
		num = num * (n - i) % p
		den = den * (i + 1) % p
	return num * pow(den, p - 2, p) % p
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	z = r + 1
	if l % z >= z / 2:
		print('YES')
	else:
		print('NO')


t = int(input())
for abrvalgs in range(0, t):
	(n, d) = map(int, input().split())
	if d // n < 2:
		print('YES')
	else:
		print('NO')


t = int(input())
for x in range(t):
	x = input().split()
	y = int(x[0]) / int(x[1])
	if y > 0.5:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
from math import gcd, ceil

def prod(a, mod=10 ** 9 + 7):
	ans = 1
	for each in a:
		ans = ans * each % mod
	return ans

def lcm(a, b):
	return a * b // gcd(a, b)

def binary(x, length=16):
	y = bin(x)[2:]
	return y if len(y) >= length else '0' * (length - len(y)) + y
for _ in range(int(input()) if True else 1):
	(l, r) = map(int, input().split())
	if r >= 2 * l:
		print('NO')
	else:
		print('YES')


for _ in range(int(input())):
	(mi, ma) = map(int, input().split())
	if mi * 2 > ma:
		print('YES')
	else:
		print('NO')


t = int(input())
for i in range(t):
	(l, r) = input().split()
	l = float(l)
	r = float(r)
	if l > r / 2:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
import heapq as h
from bisect import bisect_left, bisect_right
from types import GeneratorType
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		import os
		self.os = os
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			self.os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
from collections import defaultdict as dd, deque as dq
import math, string

def getInts():
	return [int(s) for s in input().split()]

def getInt():
	return int(input())

def getStrs():
	return [s for s in input().split()]

def getStr():
	return input()

def listStr():
	return list(input())
MOD = 10 ** 9 + 7

def solve():
	(L, R) = getInts()
	return 'YES' if R < 2 * L else 'NO'
for _ in range(getInt()):
	print(solve())


T = int(input())
while T != 0:
	T -= 1
	(l, r) = map(int, input().split())
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


for something in range(int(input())):
	(a, b) = map(int, input().split())
	if b // a < 2:
		print('YES')
	else:
		print('NO')


import sys

def main():
	inp = sys.stdin.read().strip().split('\n')[1:]
	out = []
	for s in inp:
		(l, r) = map(int, s.split())
		out.append(('NO', 'YES')[r < 2 * l])
	return out
print(*main(), sep='\n')


time = int(input())
for i in range(time):
	(left, right) = map(int, input().split())
	if right - left > left:
		print('NO')
	elif left % (right + 1) >= (right + 1) / 2:
		print('YES')
	else:
		print('NO')


t = int(input())
for _ in range(t):
	(lo, hi) = (int(i) for i in input().split())
	res = 'YES' if hi < 2 * lo else 'NO'
	print(res)


from math import *
from cmath import *
from itertools import *
from decimal import *
from fractions import *
from sys import *
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	print(['NO', 'YES'][r < 2 * l])


import sys
input = sys.stdin.readline

def main():
	(l, r) = map(int, input().split())
	r += 1
	if l % r >= r / 2:
		print('YES')
	else:
		print('NO')
for _ in range(int(input())):
	main()


for c in range(int(input())):
	(a, b) = map(int, input().split())
	opera = b + 1
	div = opera / 2
	if div > a:
		print('NO')
	else:
		print('YES')


from functools import reduce
import os
import sys
from collections import *
from math import *
from bisect import *
from heapq import *
from io import BytesIO, IOBase
input = lambda : sys.stdin.readline().rstrip('\r\n')

def value():
	return tuple(map(int, input().split()))

def arr():
	return [int(i) for i in input().split()]

def sarr():
	return [int(i) for i in input()]

def starr():
	return [str(x) for x in input().split()]

def inn():
	return int(input())

def svalue():
	return tuple(map(str, input().split()))

def parr():
	return [value() for i in range(n)]
mo = 1000000007
inf = 1e+18
div = 998244353
for _ in range(inn()):
	(l, r) = value()
	if l == 1 == r:
		print('YES')
		continue
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


for case in range(int(input())):
	(l, r) = [int(x) for x in input().split()]
	a = r + 1
	if l >= a / 2:
		print('YES')
	else:
		print('NO')


import sys

def input():
	return sys.stdin.readline().strip()

def list2d(a, b, c):
	return [[c for j in range(b)] for i in range(a)]

def list3d(a, b, c, d):
	return [[[d for k in range(c)] for j in range(b)] for i in range(a)]

def list4d(a, b, c, d, e):
	return [[[[e for l in range(d)] for k in range(c)] for j in range(b)] for i in range(a)]

def ceil(x, y=1):
	return int(-(-x // y))

def INT():
	return int(input())

def MAP():
	return map(int, input().split())

def LIST(N=None):
	return list(MAP()) if N is None else [INT() for i in range(N)]

def Yes():
	print('Yes')

def No():
	print('No')

def YES():
	print('YES')

def NO():
	print('NO')
INF = 10 ** 19
MOD = 10 ** 9 + 7
EPS = 10 ** (-10)
for _ in range(INT()):
	(l, r) = MAP()
	if r < l * 2:
		YES()
	else:
		NO()


n = int(input())
for w in range(n):
	(a, b) = map(int, input().split())
	if a >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


import sys
input = sys.stdin.readline
t = int(input())
while t:
	t -= 1
	(l, r) = list(map(int, input().split()))
	if l > r // 2:
		print('YES')
	else:
		print('NO')


import sys
IN = sys.stdin.readline
out = []
for _ in range(int(IN())):
	(L, R) = map(int, IN().split())
	if L >= (R + 1) / 2:
		out.append('YES')
	else:
		out.append('NO')
print('\n'.join(out))


import sys
import math

def II():
	return int(sys.stdin.readline())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def MI():
	return map(int, sys.stdin.readline().split())

def SI():
	return sys.stdin.readline().strip()
t = II()
for q in range(t):
	(l, r) = MI()
	if math.ceil(l / 1.5) <= r and (r + 1) / 2 > l:
		print('NO')
	else:
		print('YES')


t = int(input())
for q in range(t):
	ch = input()
	L = [int(i) for i in ch.split()]
	(a, b) = (L[0], L[1])
	if a * 2 > b:
		print('YES')
	else:
		print('NO')


def Solve():
	(l, r) = rl()
	if l > r / 2:
		print('YES')
	else:
		print('NO')
import sys
inp = sys.stdin.buffer.readline
rl = lambda : list(map(int, inp().split()))
ri = lambda : int(inp())
rs = lambda : inp().decode().strip()
Testcase = 1
Testcase = ri()
for Test in range(Testcase):
	Solve()


import typing
import sys
import math
import collections
import bisect
import itertools
import heapq
import decimal
INF = 10 ** 20
MOD = 10 ** 9 + 7

def ni():
	return int(sys.stdin.buffer.readline())

def na():
	return list(map(int, sys.stdin.buffer.readline().split()))

def na1():
	return list(map(lambda x: int(x) - 1, sys.stdin.buffer.readline().split()))

def main():
	t = ni()
	for _ in range(t):
		(l, r) = na()
		if 2 * l >= r + 1:
			print('YES')
		else:
			print('NO')
main()


rn = lambda : int(input())
rl = lambda : list(map(int, input().split()))
rns = lambda : map(int, input().split())
rs = lambda : input()
yn = lambda x: print('Yes') if x else print('No')
YN = lambda x: print('YES') if x else print('NO')
for _ in range(rn()):
	(l, r) = rns()
	if l / (r + 1) < 0.5:
		print('NO')
	else:
		print('YES')


import sys
import math
import itertools
import functools
import collections
import operator
import fileinput
import copy
import string
ORDA = 97

def ii():
	return int(input())

def mi():
	return map(int, input().split())

def li():
	return [int(i) for i in input().split()]

def lcm(a, b):
	return abs(a * b) // math.gcd(a, b)

def revn(n):
	return str(n)[::-1]

def dd():
	return collections.defaultdict(int)

def ddl():
	return collections.defaultdict(list)

def sieve(n):
	if n < 2:
		return list()
	prime = [True for _ in range(n + 1)]
	p = 3
	while p * p <= n:
		if prime[p]:
			for i in range(p * 2, n + 1, p):
				prime[i] = False
		p += 2
	r = [2]
	for p in range(3, n + 1, 2):
		if prime[p]:
			r.append(p)
	return r

def divs(n, start=2):
	r = []
	for i in range(start, int(math.sqrt(n) + 1)):
		if n % i == 0:
			if n / i == i:
				r.append(i)
			else:
				r.extend([i, n // i])
	return r

def divn(n, primes):
	divs_number = 1
	for i in primes:
		if n == 1:
			return divs_number
		t = 1
		while n % i == 0:
			t += 1
			n //= i
		divs_number *= t

def prime(n):
	if n == 2:
		return True
	if n % 2 == 0 or n <= 1:
		return False
	sqr = int(math.sqrt(n)) + 1
	for d in range(3, sqr, 2):
		if n % d == 0:
			return False
	return True

def convn(number, base):
	new_number = 0
	while number > 0:
		new_number += number % base
		number //= base
	return new_number

def cdiv(n, k):
	return n // k + (n % k != 0)

def ispal(s):
	for i in range(len(s) // 2 + 1):
		if s[i] != s[-i - 1]:
			return False
	return True
for _ in range(ii()):
	(l, r) = mi()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


N = int(input())
l = []
r = []
ans = []
for i in range(N):
	t = list(map(int, input().split()))
	if 2 * t[0] > t[1]:
		ans.append('YES')
	else:
		ans.append('NO')
for i in ans:
	print(i)


import math, sys
from sys import stdin, stdout
from collections import Counter, defaultdict, deque
input = stdin.readline
I = lambda : int(input())
li = lambda : list(map(int, input().split()))

def solve():
	(a, b) = li()
	if a * 2 > b:
		print('YES')
	else:
		print('NO')
for _ in range(I()):
	solve()


def panda(l, r):
	if 2 * l - 1 >= r:
		return 'YES'
	return 'NO'
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	print(panda(l, r))


t = int(input())
for _ in range(t):
	(l, r) = [int(i) for i in input().split()]
	if l >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	(x, y) = map(int, input().split())
	c = (y + 1) / 2
	z = x % (y + 1)
	if z >= c:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase

def main():
	c = inp()
	for i in range(c):
		vals = inlt()
		div = vals[1] + 1
		if vals[0] % div >= div / 2:
			print('YES')
		else:
			print('NO')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())
main()


t = int(input())
ans = []
for _ in range(t):
	example = input()
	(l, r) = list(map(int, example.split()))
	if l >= 2 * r - 2 * l or 2 * l > r:
		ans.append('YES')
	else:
		ans.append('NO')
for a in ans:
	print(a)


t = int(input())
for _ in range(t):
	N = input()
	l = int(N.split()[0])
	r = int(N.split()[1])
	if r - l < l:
		print('YES')
	else:
		print('NO')


t = int(input().strip())
for i in range(t):
	(l, r) = map(int, input().strip().split(' '))
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


import math
for i1 in range(int(input())):
	(l, r) = list(map(int, input().split()))
	n = 2
	if r / l >= 2:
		print('NO')
	else:
		print('YES')


def answer(l, r):
	for i in range(r + 1, 2 * l + 1):
		if l % i >= i / 2:
			return print('YES')
	return print('NO')
for _ in range(int(input())):
	(l, r) = list(map(int, input().split()))
	answer(l, r)


import math
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	flage = False
	a = r + 1
	if l % a >= a / 2:
		flage = True
	if flage:
		print('YES')
	else:
		print('NO')


n = int(input())
for i in range(n):
	L = input().split(' ')
	a = int(L[0])
	b = int(L[1])
	state = 'NO'
	if b >= 2 * a:
		pass
	else:
		state = 'YES'
	print(state)


for _ in range(int(input())):
	(L, R) = [int(i) for i in input().split(' ')]
	if R // L >= 2:
		print('NO')
	else:
		print('YES')


import math
tcs = int(input())
result = []
for case in range(tcs):
	lr = [int(s) for s in input().split()]
	l = lr[0]
	r = lr[1]
	can = r // 2 < l
	if can:
		result.append('YES')
	else:
		result.append('NO')
for res in result:
	print(res)


TC = int(input())
for __ in range(TC):
	(l, r) = list(map(int, input().split()))
	if l + 1 <= r + 1 <= l * 2:
		print('YES')
	else:
		print('NO')


import sys, string
from collections import deque, defaultdict
from math import sqrt, factorial, gcd, ceil, atan, pi, log2

def input():
	return sys.stdin.buffer.readline().decode('utf-8')
from bisect import bisect_left, bisect_right
from operator import add
MOD = int(1000000000.0) + 7
INF = float('inf')

def solve():
	(a, b) = [int(x) for x in input().split()]
	if a / (b + 1) >= 0.5:
		print('YES')
	else:
		print('NO')
T = 1
T = int(input())
for case in range(1, T + 1):
	ans = solve()


import sys
input = sys.stdin.buffer.readline
t = int(input())
for _ in range(t):
	(l, r) = [int(x) for x in input().split()]
	a = 2 * l
	ans = 'YES'
	if r >= a:
		ans = 'NO'
	print(ans)


for _ in range(int(input())):
	(a, b) = [int(x) for x in input().split()]
	if b <= 2 * a - 1:
		print('YES')
	else:
		print('NO')


inp = lambda : int(input())
strl = lambda : list(input().strip())
seq = lambda : list(map(int, input().strip().split()))

def f(arr):
	(l, r) = (arr[0], arr[1])
	if r < 2 * l:
		return 'YES'
	return 'NO'

def main():
	t = inp()
	for _ in range(t):
		a = seq()
		result = f(a)
		print(result)
main()


from __future__ import division, print_function
import os, sys
from io import BytesIO, IOBase
import math
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip

def ii():
	return int(input())

def si():
	return input()

def mi():
	return map(int, input().strip().split(' '))

def msi():
	return map(str, input().strip().split(' '))

def li():
	return list(mi())

def dmain():
	sys.setrecursionlimit(1000000)
	threading.stack_size(1024000)
	thread = threading.Thread(target=main)
	thread.start()
abc = 'abcdefghijklmnopqrstuvwxyz'
abd = {'a': 0, 'b': 1, 'c': 2, 'd': 3, 'e': 4, 'f': 5, 'g': 6, 'h': 7, 'i': 8, 'j': 9, 'k': 10, 'l': 11, 'm': 12, 'n': 13, 'o': 14, 'p': 15, 'q': 16, 'r': 17, 's': 18, 't': 19, 'u': 20, 'v': 21, 'w': 22, 'x': 23, 'y': 24, 'z': 25}
mod = 1000000007
inf = float('inf')
vow = ['a', 'e', 'i', 'o', 'u']
(dx, dy) = ([-1, 1, 0, 0], [0, 0, 1, -1])

def getKey(item):
	return item[1]

def sort2(l):
	return sorted(l, key=getKey, reverse=True)

def d2(n, m, num):
	return [[num for x in range(m)] for y in range(n)]

def isPowerOfTwo(x):
	return x and (not x & x - 1)

def decimalToBinary(n):
	return bin(n).replace('0b', '')

def ntl(n):
	return [int(i) for i in str(n)]

def ncr(n, r):
	return factorial(n) // (factorial(r) * factorial(max(n - r, 1)))

def ceil(x, y):
	if x % y == 0:
		return x // y
	else:
		return x // y + 1

def powerMod(x, y, p):
	res = 1
	x %= p
	while y > 0:
		if y & 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def gcd(x, y):
	while y:
		(x, y) = (y, x % y)
	return x

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	i = 5
	while i * i <= n:
		if n % i == 0 or n % (i + 2) == 0:
			return False
		i = i + 6
	return True

def read():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

def main():
	t = int(input())
	for i in range(t):
		(l, r) = map(int, input().split())
		if l * 2 > r:
			print('YES')
		else:
			print('NO')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


ans = []
for t in range(int(input())):
	(l, r) = map(int, input().split())
	if l * 2 > r:
		ans += ['YES']
	else:
		ans += ['NO']
print(*ans, sep='\n')


T = int(input())
for t in range(T):
	(l, r) = list(map(int, input().split(' ')))
	L = 1 + r
	U = 2 * l
	if L <= U:
		print('YES')
	else:
		print('NO')


T = int(input())
for t in range(T):
	(l, r) = list(map(int, list(input().split())))
	f = False
	if r % 2 == 0:
		if r // 2 >= l:
			f = True
	elif (r - 1) // 2 >= l:
		f = True
	if f:
		print('NO')
	else:
		print('YES')


import sys
import math
input = sys.stdin.readline
YES = 'YES'
NO = 'NO'
modulo = 10 ** 9 + 7

def solve():
	(l, r) = map(int, input().split())
	return YES if l * 2 > r else NO
for _ in range(int(input())):
	print(solve())


for _ in range(int(input())):
	(beg, end) = map(int, input().split())
	if end / 2 < beg:
		print('YES')
	else:
		print('NO')


import bisect
import math

def solve(l, r):
	p = 10 ** 9 + 7
	if 2 * l > r:
		return 'YES'
	else:
		return 'NO'
t = int(input())
ans = []
for i in range(t):
	arr = [int(x) for x in input().split()]
	l = arr[0]
	r = arr[1]
	ans.append(solve(l, r))
for test in ans:
	print(test)


def solve(l, r):
	return l % (r + 1) >= (r + 1) / 2
T = int(input())
for _ in range(T):
	a = list(map(int, input().split()))
	res = solve(a[0], a[1])
	print('YES' if res else 'NO')


import math
import string
import random
from random import randrange
from collections import deque
from collections import defaultdict

def solve(n, arr, x, y, st):
	ans = 0
	if y - x >= x:
		print('NO')
	else:
		print('YES')
	return

def main():
	t = int(input())
	while t > 0:
		t -= 1
		(x, y) = (0, 0)
		arr = []
		s = ''
		n = 0
		(x, y) = map(int, input().strip().split(' '))
		solve(n, arr, x, y, s)
	return

def test():
	arr_size = 25
	test_cases = 100
	min_range = -100
	max_range = 100
	str_size = 30
	step = 1
	for i in range(test_cases):
		k = []
		for j in range(arr_size):
			num = randrange(min_range, max_range, step)
			k.append(num)
		solve(n, arr)
		print('<-------- DEBUG ----------->')
	return
main()


n = int(input())
for c in range(n):
	(x, y) = [int(i) for i in input().strip().split(' ')]
	if 2 * x >= y + 1:
		print('YES')
	else:
		print('NO')


t = int(input())
for _ in range(0, t):
	(l, r) = map(int, input().split())
	a = r + 1
	x = l
	if x % a >= a / 2:
		print('YES')
	else:
		print('NO')


def print_result(ans):
	print(ans)

def solve(n, num_arr):
	if r + 1 > 2 * l:
		return 'NO'
	else:
		return 'YES'
t = int(input())
for i in range(1, t + 1):
	(l, r) = list(map(int, input().split()))
	ans = solve(l, r)
	print_result(ans)


import sys
input = sys.stdin.readline
for test in range(int(input())):
	[l, r] = list(map(int, input().split(' ')))
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


import sys

def get_ints():
	return list(map(int, sys.stdin.readline().strip().split()))
t = int(input())
while t > 0:
	t = t - 1
	arr = []
	arr = get_ints()
	l = arr[0]
	r = arr[1]
	r = r + 1
	if 2 * l >= r:
		print('YES')
	else:
		print('NO')


import sys, math
from heapq import *
from collections import defaultdict as dd
mod = 10 ** 9 + 7
modd = 998244353
input = lambda : sys.stdin.readline().strip()
inp = lambda : list(map(int, input().split()))
for _ in range(int(input())):
	(l, r) = inp()
	a = r - l + 1
	if a <= l:
		print('YES')
	else:
		print('NO')


for test in range(int(input())):
	(l, r) = map(int, input().split())
	a = 2 * l // 3
	print('YES' if 2 * l > r or (a + a // 2 >= l and 2 * a - 1 >= r) else 'NO')


for _ in range(int(input())):
	(m, n) = list(map(int, input().split()))
	if (n + 1) / 2 > m:
		print('NO')
	else:
		print('YES')


from sys import stdin, stdout
import math, sys, heapq
from itertools import permutations, combinations
from collections import defaultdict, deque, OrderedDict
from os import path
import random
import bisect as bi

def yes():
	print('YES')

def no():
	print('NO')
if path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

	def I():
		return int(input())

	def In():
		return map(int, input().split())
else:

	def I():
		return int(stdin.readline())

	def In():
		return map(int, stdin.readline().split())

def dict(a):
	d = {}
	for x in a:
		if d.get(x, -1) != -1:
			d[x] += 1
		else:
			d[x] = 1
	return d

def find_gt(a, x):
	i = bi.bisect_left(a, x)
	if i != len(a):
		return i
	else:
		return -1

def main():
	try:
		(a, b) = In()
		if b < a * 2:
			yes()
		else:
			no()
	except:
		pass
M = 998244353
P = 1000000007
for _ in range(I()):
	main()


t = int(input())
answers = []
for _ in range(t):
	lr = input().split()
	if (int(lr[1]) + 1) / 2 <= int(lr[0]):
		answers.append('YES')
	else:
		answers.append('NO')
for i in range(t):
	print(answers[i])


for _ in ' ' * int(input()):
	(a, b) = map(int, input().split())
	if a % (b + 1) >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


import sys
import math
input = sys.stdin.readline
t = int(input())
for w in range(t):
	(l, r) = (int(i) for i in input().split())
	if l == 1 and r == 2:
		print('NO')
	elif l >= math.ceil((r + 1) / 2):
		print('YES')
	else:
		print('NO')


n = int(input())
for _ in range(n):
	(a, b) = [int(i) for i in input().split()]
	e = (b + 1) / 2
	if a % (b + 1) >= e:
		print('YES')
	else:
		print('NO')


rr = lambda : input().strip()
rri = lambda : int(rr())
rrm = lambda : [int(x) for x in rr().split()]
from sys import stdin, stdout, setrecursionlimit
from math import ceil, factorial as fact
from heapq import *

def sol():
	(l, r) = rrm()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')
	return

def main():
	T = rri()
	for t in range(1, T + 1):
		ans = sol()
main()


from collections import deque, defaultdict

def solve():
	(l, r) = map(int, input().split())
	if r + 1 <= 2 * l:
		print('YES')
	else:
		print('NO')

def main():
	t = 1
	t = int(input())
	for _ in range(t):
		solve()
main()


test_case = int(input())
for _ in range(0, test_case):
	(l, r) = map(int, input().split())
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


t = int(input())
for _ in range(t):
	(l, r) = [int(i) for i in input().strip().split(' ')]
	a = 2 * l // 3
	c1 = r < 2 * a
	c2 = r < 2 * l
	res = 'YES' if c1 or c2 else 'NO'
	print(res)


import os
import sys
from io import BytesIO, IOBase
DEBUG_MODE = False

def main():
	T = iin()
	while T:
		T -= 1
		(l, r) = lin()
		print('YES' if l * 2 > r else 'NO')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def iin():
	return int(input())

def lin():
	return list(map(int, input().split()))
if DEBUG_MODE == True:
	import cProfile
	cProfile.run('main()')
else:
	main()


import sys
input = sys.stdin.readline

def gcd(a, b):
	if a == 0:
		return b
	return gcd(b % a, a)

def lcm(a, b):
	return a * b / gcd(a, b)

def main():
	for _ in range(int(input())):
		(l, r) = map(int, input().split())
		if 2 * l > r:
			print('YES')
		else:
			print('NO')
	return
main()


import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush, nsmallest
from math import ceil, floor, gcd, fabs, factorial, fmod, sqrt, inf, log
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction
from decimal import Decimal
mod = pow(10, 9) + 7
mod2 = 998244353

def data():
	return sys.stdin.readline().strip()

def out(var):
	sys.stdout.write(str(var) + '\n')

def outa(*var, end='\n'):
	sys.stdout.write(' '.join(map(str, var)) + end)

def l():
	return list(sp())

def sl():
	return list(ssp())

def sp():
	return map(int, data().split())

def ssp():
	return map(str, data().split())

def l1d(n, val=0):
	return [val for i in range(n)]

def l2d(n, m, val=0):
	return [l1d(n, val) for j in range(m)]
for _ in range(int(data())):
	(L, R) = sp()
	if (R + 1) / 2 <= L:
		out('YES')
		continue
	out('NO')


def ii():
	return int(input())

def li():
	return [int(i) for i in input().split()]
for t in range(ii()):
	(l, r) = li()
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


import math
from collections import deque
from sys import stdin, stdout, setrecursionlimit
from string import ascii_letters
letters = ascii_letters[:26]
from collections import defaultdict
input = stdin.readline
for _ in range(int(input())):
	(a, b) = map(int, input().split())
	if a >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


n = int(input())
for i in range(0, n):
	a = input().rstrip().split(' ')
	if int(a[0]) * 2 > int(a[1]):
		print('YES')
	else:
		print('NO')


import sys
tc = int(sys.stdin.readline().strip())
for test in range(tc):
	(l, r) = map(int, sys.stdin.readline().split())
	print('YES' if l * 2 > r else 'NO')


import os
import sys
from io import BytesIO, IOBase
import math
from itertools import permutations
from decimal import Decimal, getcontext
getcontext().prec = 25
MOD = pow(10, 9) + 7
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
for _ in range(int(input())):
	(n, k) = map(int, input().split(' '))
	if k < 2 * n:
		print('YES')
	else:
		print('NO')


mod = 10 ** 9 + 7
from math import *
import threading
import sys

def npr(n, r):
	return factorial(n) // factorial(n - r) if n >= r else 0

def lower_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] >= num:
			answer = middle
			end = middle - 1
		else:
			start = middle + 1
	return answer

def upper_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] <= num:
			answer = middle
			start = middle + 1
		else:
			end = middle - 1
	return answer

def abs(x):
	return x if x >= 0 else -x

def binary_search(li, val, lb, ub):
	ans = -1
	while lb <= ub:
		mid = (lb + ub) // 2
		if li[mid] > val:
			ub = mid - 1
		elif val > li[mid]:
			lb = mid + 1
		else:
			ans = mid
			break
	return ans

def kadane(x):
	sum_so_far = 0
	current_sum = 0
	for i in x:
		current_sum += i
		if current_sum < 0:
			current_sum = 0
		else:
			sum_so_far = max(sum_so_far, current_sum)
	return sum_so_far

def pref(li):
	pref_sum = [0]
	for i in li:
		pref_sum.append(pref_sum[-1] + i)
	return pref_sum

def graph(n, m):
	adj = dict()
	for i in range(1, n + 1):
		adj.setdefault(i, 0)
	for i in range(m):
		(a, b) = map(int, input().split())
		adj[a] += 1
		adj[b] += 1
	return adj

def SieveOfEratosthenes(n):
	prime = [True for i in range(n + 1)]
	p = 2
	li = []
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	for p in range(2, len(prime)):
		if prime[p]:
			li.append(p)
	return li
sys.setrecursionlimit(300000)
primes = SieveOfEratosthenes(1300000)

def fn(n):
	i = 2
	res = n - 1
	val = 0
	for i in range(int(sqrt(n)) + 1, 1, -1):
		val = i - 1 + int(ceil((n - i) / i))
		if val <= res:
			res = val
		else:
			break
	return res

def solve(a, b, c):
	dis = b ** 2 - 4 * a * c
	ans1 = (-b - sqrt(dis)) / (2 * a)
	print(int(ans1))
	return
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	ans = r + 1
	if l >= ans / 2:
		print('YES')
	else:
		print('NO')


t = int(input())
for q in range(t):
	(l, r) = map(int, input().split())
	if r - l < l:
		print('YES')
	else:
		print('NO')


n = int(input())
for i in range(1, n + 1):
	(j, k) = map(int, input().split())
	if 2 * j >= k + 1:
		print('YES')
	else:
		print('NO')


import sys
from array import array

def input():
	return sys.stdin.buffer.readline().decode('utf-8')
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	if l % (r + 1) * 2 >= r + 1:
		print('YES')
	else:
		print('NO')


import sys
import math
import bisect
from sys import stdin, stdout
from math import gcd, floor, sqrt, log
from collections import defaultdict as dd
from bisect import bisect_left as bl, bisect_right as br
sys.setrecursionlimit(100000000)
inp = lambda : int(input())
strng = lambda : input().strip()
jn = lambda x, l: x.join(map(str, l))
strl = lambda : list(input().strip())
mul = lambda : map(int, input().strip().split())
mulf = lambda : map(float, input().strip().split())
seq = lambda : list(map(int, input().strip().split()))
ceil = lambda x: int(x) if x == int(x) else int(x) + 1
ceildiv = lambda x, d: x // d if x % d == 0 else x // d + 1
flush = lambda : stdout.flush()
stdstr = lambda : stdin.readline()
stdint = lambda : int(stdin.readline())
stdpr = lambda x: stdout.write(str(x))
mod = 1000000007
for t in range(int(input())):
	lip = list(map(int, input().strip().split()))
	if lip[1] < 2 * lip[0]:
		print('YES')
	else:
		print('NO')


for _ in range(0, int(input())):
	(m, M) = sorted(map(int, input().split()))
	print(['NO', 'YES'][m > M // 2])


for tt in range(int(input())):
	(l, r) = map(int, input().split())
	if l == r:
		print('YES')
	else:
		ans = min(l, r) - 0.5
		ans = ans * 2
		if ans == r:
			print('YES')
		elif ans > r:
			print('YES')
		else:
			print('NO')


t = int(input())
while t > 0:
	(l, r) = list(map(int, input().split()))
	if int(2 * l / 3) > int(r / 2):
		valid = False
		for i in range(int(r / 2) + 1, int(2 * l / 3) + 1):
			if l % i >= i / 2 and r % i >= i / 2:
				valid = True
				break
		if valid:
			print('YES')
	elif r > 2 * l:
		print('NO')
	else:
		valid = False
		for i in range(r + 1, 2 * l + 1):
			if l % i >= i / 2 and r % i >= i / 2:
				valid = True
				break
		if valid:
			print('YES')
		else:
			print('NO')
	t = t - 1


import sys
import os
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
mod = 10 ** 9 + 7

def lcm(x, y):
	return x * y / gcd(x, y)

def fact(x, mod=mod):
	ans = 1
	for i in range(1, x + 1):
		ans = ans * i % mod
	return ans

def arr2D(n, m, default=0):
	return [[default for j in range(m)] for i in range(n)]

def arr3D(n, m, r, default=0):
	return [[[default for k in range(r)] for j in range(m)] for i in range(n)]

def sortDictV(x):
	return {k: v for (k, v) in sorted(x.items(), key=lambda item: item[1])}

class DSU:

	def __init__(self, length):
		self.length = length
		self.parent = [-1] * self.length

	def getParent(self, node, start):
		if node >= self.length:
			return False
		if self.parent[node] < 0:
			if start != node:
				self.parent[start] = node
			return node
		return self.getParent(self.parent[node], start)

	def union(self, node1, node2):
		parent1 = self.getParent(node1, node1)
		parent2 = self.getParent(node2, node2)
		if parent1 == parent2:
			return False
		elif self.parent[parent1] <= self.parent[parent2]:
			self.parent[parent1] += self.parent[parent2]
			self.parent[parent2] = parent1
		else:
			self.parent[parent2] += self.parent[parent1]
			self.parent[parent1] = parent2
		return True

	def getCount(self, node):
		return -self.parent[self.getParent(node, node)]

def solve(l, r):
	if r < 2 * l and l > r / 2:
		return 'YES'
	return 'NO'
for _ in range(int(input())):
	(l, r) = list(map(int, input().split()))
	print(solve(l, r))


import math
import random
import heapq, bisect
import sys
from collections import deque, defaultdict
from fractions import Fraction
import sys
import threading
from collections import defaultdict
mod = 10 ** 9 + 7
mod1 = 998244353
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

class TreeNode:

	def __init__(self, k, v):
		self.key = k
		self.value = v
		self.left = None
		self.right = None
		self.parent = None
		self.height = 1
		self.num_left = 1
		self.num_total = 1

class AvlTree:

	def __init__(self):
		self._tree = None

	def add(self, k, v):
		if not self._tree:
			self._tree = TreeNode(k, v)
			return
		node = self._add(k, v)
		if node:
			self._rebalance(node)

	def _add(self, k, v):
		node = self._tree
		while node:
			if k < node.key:
				if node.left:
					node = node.left
				else:
					node.left = TreeNode(k, v)
					node.left.parent = node
					return node.left
			elif node.key < k:
				if node.right:
					node = node.right
				else:
					node.right = TreeNode(k, v)
					node.right.parent = node
					return node.right
			else:
				node.value = v
				return

	@staticmethod
	def get_height(x):
		return x.height if x else 0

	@staticmethod
	def get_num_total(x):
		return x.num_total if x else 0

	def _rebalance(self, node):
		n = node
		while n:
			lh = self.get_height(n.left)
			rh = self.get_height(n.right)
			n.height = max(lh, rh) + 1
			balance_factor = lh - rh
			n.num_total = 1 + self.get_num_total(n.left) + self.get_num_total(n.right)
			n.num_left = 1 + self.get_num_total(n.left)
			if balance_factor > 1:
				if self.get_height(n.left.left) < self.get_height(n.left.right):
					self._rotate_left(n.left)
				self._rotate_right(n)
			elif balance_factor < -1:
				if self.get_height(n.right.right) < self.get_height(n.right.left):
					self._rotate_right(n.right)
				self._rotate_left(n)
			else:
				n = n.parent

	def _remove_one(self, node):
		replacement = node.left or node.right
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = replacement
			else:
				node.parent.right = replacement
			replacement.parent = node.parent
			node.parent = None
		else:
			self._tree = replacement
			replacement.parent = None
		node.left = None
		node.right = None
		node.parent = None
		self._rebalance(replacement)

	def _remove_leaf(self, node):
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = None
			else:
				node.parent.right = None
			self._rebalance(node.parent)
		else:
			self._tree = None
		node.parent = None
		node.left = None
		node.right = None

	def remove(self, k):
		node = self._get_node(k)
		if not node:
			return
		if AvlTree._is_leaf(node):
			self._remove_leaf(node)
			return
		if node.left and node.right:
			nxt = AvlTree._get_next(node)
			node.key = nxt.key
			node.value = nxt.value
			if self._is_leaf(nxt):
				self._remove_leaf(nxt)
			else:
				self._remove_one(nxt)
			self._rebalance(node)
		else:
			self._remove_one(node)

	def get(self, k):
		node = self._get_node(k)
		return node.value if node else -1

	def _get_node(self, k):
		if not self._tree:
			return None
		node = self._tree
		while node:
			if k < node.key:
				node = node.left
			elif node.key < k:
				node = node.right
			else:
				return node
		return None

	def get_at(self, pos):
		x = pos + 1
		node = self._tree
		while node:
			if x < node.num_left:
				node = node.left
			elif node.num_left < x:
				x -= node.num_left
				node = node.right
			else:
				return (node.key, node.value)
		raise IndexError('Out of ranges')

	@staticmethod
	def _is_left(node):
		return node.parent.left and node.parent.left == node

	@staticmethod
	def _is_leaf(node):
		return node.left is None and node.right is None

	def _rotate_right(self, node):
		if not node.parent:
			self._tree = node.left
			node.left.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.left
			node.left.parent = node.parent
		else:
			node.parent.right = node.left
			node.left.parent = node.parent
		bk = node.left.right
		node.left.right = node
		node.parent = node.left
		node.left = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	def _rotate_left(self, node):
		if not node.parent:
			self._tree = node.right
			node.right.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.right
			node.right.parent = node.parent
		else:
			node.parent.right = node.right
			node.right.parent = node.parent
		bk = node.right.left
		node.right.left = node
		node.parent = node.right
		node.right = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	@staticmethod
	def _get_next(node):
		if not node.right:
			return node.parent
		n = node.right
		while n.left:
			n = n.left
		return n

class SegmentTree1:

	def __init__(self, data, default=2 ** 32, func=lambda a, b: min(a, b)):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class SegmentTree:

	def __init__(self, data, default=0, func=lambda a, b: max(a, b)):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class Factorial:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorials = [1, 1]
		self.invModulos = [0, 1]
		self.invFactorial_ = [1, 1]

	def calc(self, n):
		if n <= -1:
			print('Invalid argument to calculate n!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.factorials):
			return self.factorials[n]
		nextArr = [0] * (n + 1 - len(self.factorials))
		initialI = len(self.factorials)
		prev = self.factorials[-1]
		m = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * i % m
		self.factorials += nextArr
		return self.factorials[n]

	def inv(self, n):
		if n <= -1:
			print('Invalid argument to calculate n^(-1)')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		p = self.MOD
		pi = n % p
		if pi < len(self.invModulos):
			return self.invModulos[pi]
		nextArr = [0] * (n + 1 - len(self.invModulos))
		initialI = len(self.invModulos)
		for i in range(initialI, min(p, n + 1)):
			next = -self.invModulos[p % i] * (p // i) % p
			self.invModulos.append(next)
		return self.invModulos[pi]

	def invFactorial(self, n):
		if n <= -1:
			print('Invalid argument to calculate (n^(-1))!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.invFactorial_):
			return self.invFactorial_[n]
		self.inv(n)
		nextArr = [0] * (n + 1 - len(self.invFactorial_))
		initialI = len(self.invFactorial_)
		prev = self.invFactorial_[-1]
		p = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * self.invModulos[i % p] % p
		self.invFactorial_ += nextArr
		return self.invFactorial_[n]

class Combination:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorial = Factorial(MOD)

	def ncr(self, n, k):
		if k < 0 or n < k:
			return 0
		k = min(k, n - k)
		f = self.factorial
		return f.calc(n) * f.invFactorial(max(n - k, k)) * f.invFactorial(min(k, n - k)) % self.MOD

def powm(a, n, m):
	if a == 1 or n == 0:
		return 1
	if n % 2 == 0:
		s = powm(a, n // 2, m)
		return s * s % m
	else:
		return a * powm(a, n - 1, m) % m

def sort_list(list1, list2):
	zipped_pairs = zip(list2, list1)
	z = [x for (_, x) in sorted(zipped_pairs)]
	return z

def product(l):
	por = 1
	for i in range(len(l)):
		por *= l[i]
	return por

def binarySearchCount(arr, n, key):
	left = 0
	right = n - 1
	count = 0
	while left <= right:
		mid = int((right + left) / 2)
		if arr[mid] <= key:
			count = mid + 1
			left = mid + 1
		else:
			right = mid - 1
	return count

def countdig(n):
	c = 0
	while n > 0:
		n //= 10
		c += 1
	return c

def binary(x, length):
	y = bin(x)[2:]
	return y if len(y) >= length else '0' * (length - len(y)) + y

def countGreater(arr, n, k):
	l = 0
	r = n - 1
	leftGreater = n
	while l <= r:
		m = int(l + (r - l) / 2)
		if arr[m] >= k:
			leftGreater = m
			r = m - 1
		else:
			l = m + 1
	return n - leftGreater

class TrieNode:

	def __init__(self):
		self.children = [None] * 26
		self.isEndOfWord = False

class Trie:

	def __init__(self):
		self.root = self.getNode()

	def getNode(self):
		return TrieNode()

	def _charToIndex(self, ch):
		return ord(ch) - ord('a')

	def insert(self, key):
		pCrawl = self.root
		length = len(key)
		for level in range(length):
			index = self._charToIndex(key[level])
			if not pCrawl.children[index]:
				pCrawl.children[index] = self.getNode()
			pCrawl = pCrawl.children[index]
		pCrawl.isEndOfWord = True

	def search(self, key):
		pCrawl = self.root
		length = len(key)
		for level in range(length):
			index = self._charToIndex(key[level])
			if not pCrawl.children[index]:
				return False
			pCrawl = pCrawl.children[index]
		return pCrawl != None and pCrawl.isEndOfWord

class Node:

	def __init__(self, data):
		self.data = data
		self.count = 0
		self.left = None
		self.right = None

class BinaryTrie:

	def __init__(self):
		self.root = Node(0)

	def insert(self, pre_xor):
		self.temp = self.root
		for i in range(31, -1, -1):
			val = pre_xor & 1 << i
			if val:
				if not self.temp.right:
					self.temp.right = Node(0)
				self.temp = self.temp.right
				self.temp.count += 1
			if not val:
				if not self.temp.left:
					self.temp.left = Node(0)
				self.temp = self.temp.left
				self.temp.count += 1
		self.temp.data = pre_xor

	def query(self, xor):
		self.temp = self.root
		for i in range(31, -1, -1):
			val = xor & 1 << i
			if not val:
				if self.temp.left and self.temp.left.count > 0:
					self.temp = self.temp.left
				elif self.temp.right:
					self.temp = self.temp.right
			elif self.temp.right and self.temp.right.count > 0:
				self.temp = self.temp.right
			elif self.temp.left:
				self.temp = self.temp.left
			self.temp.count -= 1
		return xor ^ self.temp.data
for ik in range(int(input())):
	(l, r) = map(int, input().split())
	if l % (r + 1) >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')


for iN in range(int(input())):
	(r, l) = [int(x) for x in input().split()]
	a = (l - r) * 2
	print('NO' if l // r != 1 else 'YES', end='\n')


def func(a, b):
	if b // 2 < a:
		print('YES')
		return
	print('NO')
t = int(input())
for _ in range(t):
	(a, b) = map(int, input().split())
	func(a, b)


t = int(input())
for i in range(0, t):
	(a, b) = map(int, input().split())
	if a > b / 2:
		print('YES')
	else:
		print('NO')


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	cur = 'YES' if l >= r - l + 1 else 'NO'
	print(cur)


def f():
	(l, r) = map(int, input().split())
	return 2 * l > r
t = int(input())
for i in range(t):
	if f():
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout
from math import gcd, sqrt, factorial, pi, inf
from collections import deque, defaultdict
input = stdin.readline
R = lambda : map(int, input().split())
I = lambda : int(input())
S = lambda : input().rstrip('\n')
L = lambda : list(R())
P = lambda x: stdout.write(str(x) + '\n')
lcm = lambda x, y: x * y // gcd(x, y)
hg = lambda x, y: (y + x - 1) // x * x
pw = lambda x: 1 if x == 1 else 1 + pw(x // 2)
chk = lambda x: chk(x // 2) if not x % 2 else True if x == 1 else False
sm = lambda x: (x ** 2 + x) // 2
N = 10 ** 9 + 7
for _ in range(I()):
	(l, r) = R()
	print('YES' if 2 * l > r else 'NO')


from math import *
from sys import *
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	k = (r + 1) / 2
	if l >= k:
		print('YES')
	else:
		print('NO')


def solve(l, r):
	big = float('inf')
	small = float('-inf')
	return r < 2 * l

def main():
	t = int(input())
	for i in range(t):
		d = input()
		d = [int(i) for i in d.split()]
		a = d[0]
		b = d[1]
		ans = solve(a, b)
		if ans:
			print('YES')
		else:
			print('NO')
main()


from sys import stdin, stdout

def INPUT():
	return list((int(i) for i in stdin.readline().split()))
import math

def inp():
	return stdin.readline()

def out(x):
	return stdout.write(x)
import math as M
MOD = 10 ** 9 + 7
from random import randint as R
for _ in range(int(input())):
	(l, r) = INPUT()
	if l == 1 and r == 1:
		print('YES')
		continue
	if l == 1:
		print('NO')
		continue
	if (r + 1) / 2 <= l or (l - 1) / 2 >= r - l + 1:
		print('YES')
		continue
	print('NO')


from sys import *
from collections import defaultdict as dd
from math import *
from bisect import *

def sinp():
	return input()

def inp():
	return int(sinp())

def minp():
	return map(int, sinp().split())

def linp():
	return list(minp())

def strl():
	return list(sinp())

def pr(x):
	print(x)
mod = int(1000000000.0 + 7)
for _ in range(inp()):
	(l, r) = minp()
	a = r + 1
	if r % a >= a / 2 and l % a >= a / 2:
		pr('YES')
	else:
		pr('NO')


t = int(input())
for i in range(t):
	(l, r) = list(map(int, input().split()))
	a = r + 1
	s = False
	if l % a >= a / 2 and r % a >= a / 2:
		s = True
	else:
		s = False
		print('NO')
	if s:
		print('YES')


import sys, math, itertools
from collections import Counter, deque, defaultdict
from bisect import bisect_left, bisect_right
mod = 10 ** 9 + 7
INF = float('inf')

def inp():
	return int(sys.stdin.readline())

def inpl():
	return list(map(int, sys.stdin.readline().split()))
for _ in range(inp()):
	(l, r) = inpl()
	res = False
	if l * 2 > r:
		res = True
	if l // 3 * 2 * 2 > r:
		res = True
	print('YES' if res else 'NO')


import sys, math, cmath, time
start_time = time.time()

def solve():
	(l, r) = invr()
	print('YES' if l > r // 2 else 'NO')

def main():
	global tt
	if not ONLINE_JUDGE:
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	t = 1
	t = inp()
	for tt in range(1, t + 1):
		solve()
	if not ONLINE_JUDGE:
		print('Time Elapsed :', time.time() - start_time, 'seconds')
		sys.stdout.close()

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	return input().strip()

def invr():
	return map(int, input().split())

def counter(a):
	q = [0] * max(a)
	for i in range(len(a)):
		q[a[i] - 1] = q[a[i] - 1] + 1
	return q

def counter_elements(a):
	q = dict()
	for i in range(len(a)):
		if a[i] not in q:
			q[a[i]] = 0
		q[a[i]] = q[a[i]] + 1
	return q

def string_counter(a):
	q = [0] * 26
	for i in range(len(a)):
		q[ord(a[i]) - 97] = q[ord(a[i]) - 97] + 1
	return q

def factorial(n, m=1000000007):
	q = 1
	for i in range(n):
		q = q * (i + 1) % m
	return q

def factors(n):
	q = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			q.append(i)
			q.append(n // i)
	return list(sorted(list(set(q))))

def prime_factors(n):
	q = []
	while n % 2 == 0:
		q.append(2)
		n = n // 2
	for i in range(3, int(n ** 0.5) + 1, 2):
		while n % i == 0:
			q.append(i)
			n = n // i
	if n > 2:
		q.append(n)
	return list(sorted(q))

def transpose(a):
	(n, m) = (len(a), len(a[0]))
	b = [[0] * n for i in range(m)]
	for i in range(m):
		for j in range(n):
			b[i][j] = a[j][i]
	return b

def power_two(x):
	return x and (not x & x - 1)

def ceil(a, b):
	return -(-a // b)

def seive(n):
	a = [1]
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p ** 2, n + 1, p):
				prime[i] = False
		p = p + 1
	for p in range(2, n + 1):
		if prime[p]:
			a.append(p)
	return a

def ncr(n, r):
	return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

def npr(n, r):
	return math.factorial(n) // math.factorial(n - r)
ONLINE_JUDGE = __debug__
if ONLINE_JUDGE:
	input = sys.stdin.readline
main()


import sys
import math
import bisect
from sys import stdin, stdout
from math import gcd, floor, sqrt, log2, ceil
from collections import defaultdict as dd
from bisect import bisect_left as bl, bisect_right as br
from bisect import insort
from collections import Counter
from collections import deque
from heapq import heappush, heappop, heapify
from itertools import permutations, combinations
mod = int(1000000000.0) + 7
ip = lambda : int(stdin.readline())
inp = lambda : map(int, stdin.readline().split())
ips = lambda : stdin.readline().rstrip()
out = lambda x: stdout.write(str(x) + '\n')
t = ip()
for _ in range(t):
	(l, r) = inp()
	if r >= 2 * l:
		ans = 'NO'
	else:
		ans = 'YES'
	out(ans)


def possible(l, r):
	small = r // 2
	if small < l:
		return True
	large = 2 * l
	if large > r:
		return True
	return False
for t in range(int(input())):
	(l, r) = map(int, input().split())
	if possible(l, r):
		print('YES')
	else:
		print('NO')


import sys
import math
input = sys.stdin.readline

def get_int():
	return int(input().strip())

def get_int_list():
	return list(map(int, input().strip().split()))

def get_char_list():
	return list(input().strip())
cases = get_int()
for _ in range(cases):
	(l, r) = get_int_list()
	if r - l >= l:
		print('NO')
	else:
		print('YES')


from sys import stdin, stdout
mp = lambda : map(int, stdin.readline().split())
for _ in range(int(input())):
	(l, r) = mp()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


def main():
	(l, r) = map(int, input().split())
	if 2 * l >= r + 1:
		print('YES')
	else:
		print('NO')
t = int(input())
for i in range(t):
	main()


import math
for t in range(int(input())):
	(l, r) = [int(a) for a in input().split()]
	m = int(math.ceil(l * 2))
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


from math import ceil
t = int(input())

def solve():
	(l, m) = list(map(int, input().split()))
	if m < 2 * l:
		print('YES')
	else:
		print('NO')
	return
for i in range(t):
	solve()


t = int(input())
ans = [''] * t
for i in range(t):
	(l, r) = [int(x) for x in input().split()]
	u = (r + 1) / 2
	if l >= u and r >= u:
		ans[i] = 'YES'
	else:
		ans[i] = 'NO'
for an in ans:
	print(an)


n = int(input())
while n:
	(a, b) = map(int, input().split())
	if b < a * 2:
		print('YES')
	else:
		print('NO')
	n -= 1


def market(l, r):
	if 2 * l > r:
		print('YES')
	else:
		print('NO')
t = int(input())
for i in range(0, t):
	lr = list(map(int, input().strip().split()))
	market(lr[0], lr[1])


T = int(input())
for i in range(T):
	(l, r) = map(int, input().split())
	if l / r > 0.5:
		print('YES')
	else:
		print('NO')


fast = lambda : stdin.readline().strip()
zzz = lambda : [int(i) for i in fast().split()]
(z, zz) = (input, lambda : list(map(int, z().split())))
(szz, graph, mod, szzz) = (lambda : sorted(zz()), {}, 10 ** 9 + 7, lambda : sorted(zzz()))
from re import *
from sys import *
from math import *
from heapq import *
from queue import *
from bisect import *
from string import *
from itertools import *
from collections import *
from math import factorial as f
from bisect import bisect as bs
from bisect import bisect_left as bsl
from collections import Counter as cc
from itertools import accumulate as ac

def lcd(xnum1, xnum2):
	return xnum1 * xnum2 // gcd(xnum1, xnum2)

def output(answer):
	stdout.write(str(answer))
num = int(z())
for _ in range(num):
	(n, m) = zzz()
	print('YES' if n * 2 > m else 'NO')


import bisect
import collections
import copy
import functools
import heapq
import itertools
import math
import random
import re
import sys
import time
import string
from typing import List
sys.setrecursionlimit(99999)
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	if 2 * l - r >= 1 or l == r:
		print('YES')
	else:
		print('NO')


def si():
	return str(input())

def ii():
	return int(input())

def mi():
	return map(int, input().split())

def li():
	return list(mi())
t = int(input())
for _ in range(t):
	(l, r) = mi()
	if (r + 1) / 2 <= l:
		print('YES')
	else:
		print('NO')


from sys import stdin
input = stdin.readline

def A():
	t = int(input())
	for __ in range(t):
		(l, r) = map(int, input().split())
		if 2 * l > r:
			print('YES')
		else:
			print('NO')

def B():
	t = int(input())
	for __ in range(t):
		_ = 0

def C():
	t = int(input())
	for __ in range(t):
		_ = 0

def D():
	t = int(input())
	for __ in range(t):
		_ = 0
A()


import sys, os, io
I = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
for tc in range(1, 1 + int(I())):
	(l, r) = map(int, I().split())
	print('YES' if l + l > r else 'NO')


t = int(input())
for i in range(0, t):
	l1 = [int(x) for x in input().split()]
	n1 = l1[0]
	n2 = l1[1]
	val1 = n1 * 2
	val2 = n2 + 1
	if val1 >= val2:
		print('YES')
	else:
		print('NO')


from bisect import *
from collections import *
from math import gcd, ceil, sqrt, floor, inf
from heapq import *
from typing import List
from itertools import *
from operator import add, mul, sub, xor, truediv, floordiv
from functools import *
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def RL():
	return map(int, sys.stdin.readline().rstrip().split())

def RLL():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def N():
	return int(input())

@lru_cache(None)
def fact(x, mod=0):
	if x < 2:
		return 1
	if not mod:
		return fact(x - 1) * x
	return fact(x - 1, mod) * x % mod

@lru_cache(None)
def per(i, j, mod=0):
	if i < j:
		return 0
	if not mod:
		return fact(i) // fact(i - j)
	ans = 1
	for k in range(i - j + 1, i + 1):
		ans = ans * k % mod
	return ans

@lru_cache(None)
def com(i, j, mod=0):
	if i < j:
		return 0
	if not mod:
		return per(i, j) // fact(j)
	return per(i, j) * inverse(fact(j), mod) % mod

def catalan(n):
	return com(2 * n, n) // (n + 1)

def linc(f, t, l, r):
	while l < r:
		mid = (l + r) // 2
		if t > f(mid):
			l = mid + 1
		else:
			r = mid
	return l

def rinc(f, t, l, r):
	while l < r:
		mid = (l + r + 1) // 2
		if t < f(mid):
			r = mid - 1
		else:
			l = mid
	return l

def ldec(f, t, l, r):
	while l < r:
		mid = (l + r) // 2
		if t < f(mid):
			l = mid + 1
		else:
			r = mid
	return l

def rdec(f, t, l, r):
	while l < r:
		mid = (l + r + 1) // 2
		if t > f(mid):
			r = mid - 1
		else:
			l = mid
	return l

def isprime(n):
	for i in range(2, int(n ** 0.5) + 1):
		if n % i == 0:
			return False
	return True

def binfun(x):
	c = 0
	for w in arr:
		c += ceil(w / x)
	return c

def lowbit(n):
	return n & -n

def inverse(a, m):
	a %= m
	if a <= 1:
		return a
	return (1 - inverse(m, a) * m) // a % m

class BIT:

	def __init__(self, arr):
		self.arr = arr
		self.n = len(arr) - 1

	def update(self, x, v):
		while x <= self.n:
			self.arr[x] += v
			x += x & -x

	def query(self, x):
		ans = 0
		while x:
			ans += self.arr[x]
			x &= x - 1
		return ans

class smt:

	def __init__(self, l, r, arr):
		self.l = l
		self.r = r
		self.value = (1 << 31) - 1 if l < r else arr[l]
		mid = (l + r) // 2
		if l < r:
			self.left = smt(l, mid, arr)
			self.right = smt(mid + 1, r, arr)
			self.value &= self.left.value & self.right.value

	def setvalue(self, x, val):
		if self.l == self.r:
			self.value = val
			return
		mid = (self.l + self.r) // 2
		if x <= mid:
			self.left.setvalue(x, val)
		else:
			self.right.setvalue(x, val)
		self.value = self.left.value & self.right.value

	def ask(self, l, r):
		if l <= self.l and r >= self.r:
			return self.value
		val = (1 << 31) - 1
		mid = (self.l + self.r) // 2
		if l <= mid:
			val &= self.left.ask(l, r)
		if r > mid:
			val &= self.right.ask(l, r)
		return val

class DSU:

	def __init__(self, n):
		self.c = [-1] * n

	def same(self, x, y):
		return self.find(x) == self.find(y)

	def find(self, x):
		if self.c[x] < 0:
			return x
		self.c[x] = self.find(self.c[x])
		return self.c[x]

	def union(self, u, v):
		(u, v) = (self.find(u), self.find(v))
		if u == v:
			return False
		if self.c[u] < self.c[v]:
			(u, v) = (v, u)
		self.c[u] += self.c[v]
		self.c[v] = u
		return True

	def size(self, x):
		return -self.c[self.find(x)]

class UFS:

	def __init__(self, n):
		self.parent = [i for i in range(n)]
		self.ranks = [0] * n

	def find(self, x):
		if x != self.parent[x]:
			self.parent[x] = self.find(self.parent[x])
		return self.parent[x]

	def union(self, u, v):
		(pu, pv) = (self.find(u), self.find(v))
		if pu == pv:
			return False
		if self.ranks[pu] >= self.ranks[pv]:
			self.parent[pv] = pu
			if self.ranks[pv] == self.ranks[pu]:
				self.ranks[pu] += 1
		else:
			self.parent[pu] = pv

def Prime(n):
	c = 0
	prime = []
	flag = [0] * (n + 1)
	for i in range(2, n + 1):
		if not flag[i]:
			prime.append(i)
			c += 1
		for j in range(c):
			if i * prime[j] > n:
				break
			flag[i * prime[j]] = prime[j]
			if i % prime[j] == 0:
				break
	return prime

def dij(s, graph):
	d = {}
	d[s] = 0
	heap = [(0, s)]
	seen = set()
	while heap:
		(dis, u) = heappop(heap)
		if u in seen:
			continue
		for v in graph[u]:
			if v not in d or d[v] > d[u] + graph[u][v]:
				d[v] = d[u] + graph[u][v]
				heappush(heap, (d[v], v))
	return d
t = N()
for i in range(t):
	(l, r) = RL()
	ans = 'YES' if r < l * 2 else 'NO'
	print(ans)


t = int(input())
for tt in range(t):
	(l, r) = map(int, input().split())
	b = 2 * l
	if b > r:
		print('YES')
	else:
		print('NO')


for _ in range(int(input())):
	a = list(map(int, input().split()))
	x = max(a)
	y = min(a)
	if y > x / 2:
		print('YES')
	else:
		print('NO')


from itertools import permutations
from collections import defaultdict
from math import *
import os
import sys
from io import BytesIO, IOBase
from heapq import nlargest
from bisect import *
import copy
import itertools
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))

def input():
	return sys.stdin.readline().rstrip('\r\n')
t = int(input())
while t:
	t -= 1
	(l, r) = map(int, input().split())
	if l + l <= r:
		print('NO')
	else:
		print('YES')


from sys import stdin, stdout
import heapq
import cProfile
from collections import Counter, defaultdict, deque
from functools import reduce
import math
import threading
import sys
import time

def get_int():
	return int(stdin.readline().strip())

def get_tuple():
	return map(int, stdin.readline().split())

def get_list():
	return list(map(int, stdin.readline().split()))

def solve():
	(l, r) = get_tuple()
	if l >= (r + 1) / 2:
		print('YES')
	else:
		print('NO')

def main():
	solve()
TestCases = True
if TestCases:
	for i in range(get_int()):
		main()
else:
	main()


import sys
try:
	(sys.stdin, sys.stdout) = (open('in.txt', 'r'), open('out.txt', 'w'))
except:
	pass
ii1 = lambda : int(sys.stdin.readline().strip())
is1 = lambda : sys.stdin.readline().strip()
iia = lambda : list(map(int, sys.stdin.readline().strip().split()))
isa = lambda : sys.stdin.readline().strip().split()
mod = int(1000000000.0 + 7)
from collections import *
from math import *
from itertools import *
for _ in range(ii1()):
	(l, r) = iia()
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


numCases = int(input())
results = []
for i in range(0, numCases):
	(l, r) = map(int, input().split())
	if r < 2 * l:
		results.append('YES')
	else:
		results.append('NO')
for i in results:
	print(i)


from sys import stdin
tt = int(stdin.readline())
for loop in range(tt):
	(l, r) = map(int, stdin.readline().split())
	a = r + 1
	if l // a == r // a and l % a >= a / 2:
		print('YES')
	else:
		print('NO')


import sys

def main():
	(n, m) = map(int, sys.stdin.readline().split())
	if n * 2 > m:
		print('YES')
	else:
		print('NO')
for i in range(int(sys.stdin.readline().strip())):
	main()


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def update(bit, i):
	while i < len(bit):
		bit[i] += 1
		i += i & -i

def getsum(bit, i):
	res = 0
	while i > 0:
		res += bit[i]
		i -= i & -i
	return res
import math
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


def solve(l, r):
	if l * 2 <= r:
		return 'NO'
	return 'YES'
T = int(input())
for t in range(T):
	(l, r) = list(map(int, input().split()))
	ans = solve(l, r)
	print(ans)


import sys
input = sys.stdin.readline

def inp():
	return int(input())

def inps():
	return input().rstrip()

def inpl():
	return list(map(int, input().split()))

def inpls():
	return list(map(str, input().split()))

def _debug(obj):
	print(obj, file=sys.stderr)
from math import gcd, floor, ceil, factorial
import itertools as it
from collections import deque, defaultdict
from collections import Counter

def lcd(a, b):
	return a * b // gcd(a, b)

def chmin(dp, i, x):
	if x < dp[i]:
		dp[i] = x
		return True
	return False

def chmax(dp, i, x):
	if x > dp[i]:
		dp[i] = x
		return True
	return False
t = inp()
for _ in range(t):
	(a, b) = inpl()
	if b >= 2 * a:
		print('NO')
	else:
		print('YES')


from math import *
tc = int(input())
for t in range(tc):
	(n, k) = map(int, input().split())
	a = n % (k + 1)
	b = ceil((k + 1) / 2)
	if a >= b:
		print(f'YES')
	else:
		print(f'NO')


import sys

def get_ints():
	return map(int, sys.stdin.readline().strip().split())
testCases = int(input())
for i in range(testCases):
	(l, r) = get_ints()
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


mod = int(1000000000.0 + 7)

def inverse_mod(p, mod):
	return pow(p, mod - 2, mod)
fact = [1, 1]
for i in range(2, 100001):
	fact.append(i * fact[i - 1] % mod)
t = int(input())
while t:
	t -= 1
	(l, r) = map(int, input().split())
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


t = int(input())
for _ in range(t):
	(n, m) = map(int, input().split())
	x = max(n, m)
	if n % (x + 1) >= (x + 1) / 2 and m % (x + 1) >= (x + 1) / 2:
		print('YES')
	else:
		print('NO')


T = int(input())
for _ in range(T):
	(l, r) = map(int, input().split())
	tar = (r + 1) / 2
	if l >= tar:
		print('YES')
	else:
		print('NO')


from math import ceil
for t in range(int(input())):
	(l, r) = [int(l) for l in input().split()]
	ans = r + 1
	if l % ans >= ceil(ans / 2) and r % ans >= ceil(ans / 2):
		print('YES')
	else:
		print('NO')


for test in range(int(input())):
	period = list(map(int, input().split()))
	if period[1] // period[0] < 2:
		print('YES')
	else:
		print('NO')


from sys import stdin
nii = lambda : map(int, stdin.readline().split())
lnii = lambda : list(map(int, stdin.readline().split()))
t = int(input())
for i in range(t):
	(l, r) = nii()
	a = r + 1
	if l % a >= a / 2 and r % a >= a / 2:
		print('YES')
	else:
		print('NO')


def solve():
	(l, r) = map(int, input().split())
	if l >= r - l + 1:
		print('YES')
	else:
		print('NO')
tests = int(input())
while tests > 0:
	tests -= 1
	solve()


def packs(l, r):
	return bool(l >= (r + 1) / 2)
t = int(input())
for i in range(t):
	(l, r) = input().split()
	if packs(int(l), int(r)) == True:
		print('YES')
	else:
		print('NO')


import sys
import math
from collections import defaultdict, Counter
input = sys.stdin.readline

def print(x):
	sys.stdout.write(str(x) + '\n')
t = int(input())
for i in range(t):
	(l, r) = map(int, input().split())
	if l > r // 2:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
import heapq as h
from bisect import bisect_left, bisect_right
from types import GeneratorType
BUFSIZE = 8192

class SortedList:

	def __init__(self, iterable=[], _load=200):
		values = sorted(iterable)
		self._len = _len = len(values)
		self._load = _load
		self._lists = _lists = [values[i:i + _load] for i in range(0, _len, _load)]
		self._list_lens = [len(_list) for _list in _lists]
		self._mins = [_list[0] for _list in _lists]
		self._fen_tree = []
		self._rebuild = True

	def _fen_build(self):
		self._fen_tree[:] = self._list_lens
		_fen_tree = self._fen_tree
		for i in range(len(_fen_tree)):
			if i | i + 1 < len(_fen_tree):
				_fen_tree[i | i + 1] += _fen_tree[i]
		self._rebuild = False

	def _fen_update(self, index, value):
		if not self._rebuild:
			_fen_tree = self._fen_tree
			while index < len(_fen_tree):
				_fen_tree[index] += value
				index |= index + 1

	def _fen_query(self, end):
		if self._rebuild:
			self._fen_build()
		_fen_tree = self._fen_tree
		x = 0
		while end:
			x += _fen_tree[end - 1]
			end &= end - 1
		return x

	def _fen_findkth(self, k):
		_list_lens = self._list_lens
		if k < _list_lens[0]:
			return (0, k)
		if k >= self._len - _list_lens[-1]:
			return (len(_list_lens) - 1, k + _list_lens[-1] - self._len)
		if self._rebuild:
			self._fen_build()
		_fen_tree = self._fen_tree
		idx = -1
		for d in reversed(range(len(_fen_tree).bit_length())):
			right_idx = idx + (1 << d)
			if right_idx < len(_fen_tree) and k >= _fen_tree[right_idx]:
				idx = right_idx
				k -= _fen_tree[idx]
		return (idx + 1, k)

	def _delete(self, pos, idx):
		_lists = self._lists
		_mins = self._mins
		_list_lens = self._list_lens
		self._len -= 1
		self._fen_update(pos, -1)
		del _lists[pos][idx]
		_list_lens[pos] -= 1
		if _list_lens[pos]:
			_mins[pos] = _lists[pos][0]
		else:
			del _lists[pos]
			del _list_lens[pos]
			del _mins[pos]
			self._rebuild = True

	def _loc_left(self, value):
		if not self._len:
			return (0, 0)
		_lists = self._lists
		_mins = self._mins
		(lo, pos) = (-1, len(_lists) - 1)
		while lo + 1 < pos:
			mi = lo + pos >> 1
			if value <= _mins[mi]:
				pos = mi
			else:
				lo = mi
		if pos and value <= _lists[pos - 1][-1]:
			pos -= 1
		_list = _lists[pos]
		(lo, idx) = (-1, len(_list))
		while lo + 1 < idx:
			mi = lo + idx >> 1
			if value <= _list[mi]:
				idx = mi
			else:
				lo = mi
		return (pos, idx)

	def _loc_right(self, value):
		if not self._len:
			return (0, 0)
		_lists = self._lists
		_mins = self._mins
		(pos, hi) = (0, len(_lists))
		while pos + 1 < hi:
			mi = pos + hi >> 1
			if value < _mins[mi]:
				hi = mi
			else:
				pos = mi
		_list = _lists[pos]
		(lo, idx) = (-1, len(_list))
		while lo + 1 < idx:
			mi = lo + idx >> 1
			if value < _list[mi]:
				idx = mi
			else:
				lo = mi
		return (pos, idx)

	def add(self, value):
		_load = self._load
		_lists = self._lists
		_mins = self._mins
		_list_lens = self._list_lens
		self._len += 1
		if _lists:
			(pos, idx) = self._loc_right(value)
			self._fen_update(pos, 1)
			_list = _lists[pos]
			_list.insert(idx, value)
			_list_lens[pos] += 1
			_mins[pos] = _list[0]
			if _load + _load < len(_list):
				_lists.insert(pos + 1, _list[_load:])
				_list_lens.insert(pos + 1, len(_list) - _load)
				_mins.insert(pos + 1, _list[_load])
				_list_lens[pos] = _load
				del _list[_load:]
				self._rebuild = True
		else:
			_lists.append([value])
			_mins.append(value)
			_list_lens.append(1)
			self._rebuild = True

	def discard(self, value):
		_lists = self._lists
		if _lists:
			(pos, idx) = self._loc_right(value)
			if idx and _lists[pos][idx - 1] == value:
				self._delete(pos, idx - 1)

	def remove(self, value):
		_len = self._len
		self.discard(value)
		if _len == self._len:
			raise ValueError('{0!r} not in list'.format(value))

	def pop(self, index=-1):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		value = self._lists[pos][idx]
		self._delete(pos, idx)
		return value

	def bisect_left(self, value):
		(pos, idx) = self._loc_left(value)
		return self._fen_query(pos) + idx

	def bisect_right(self, value):
		(pos, idx) = self._loc_right(value)
		return self._fen_query(pos) + idx

	def count(self, value):
		return self.bisect_right(value) - self.bisect_left(value)

	def __len__(self):
		return self._len

	def __getitem__(self, index):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		return self._lists[pos][idx]

	def __delitem__(self, index):
		(pos, idx) = self._fen_findkth(self._len + index if index < 0 else index)
		self._delete(pos, idx)

	def __contains__(self, value):
		_lists = self._lists
		if _lists:
			(pos, idx) = self._loc_left(value)
			return idx < len(_lists[pos]) and _lists[pos][idx] == value
		return False

	def __iter__(self):
		return (value for _list in self._lists for value in _list)

	def __reversed__(self):
		return (value for _list in reversed(self._lists) for value in reversed(_list))

	def __repr__(self):
		return 'SortedList({0})'.format(list(self))

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		import os
		self.os = os
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			self.os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
import collections as col
import math, string

def getInts():
	return [int(s) for s in input().split()]

def getInt():
	return int(input())

def getStrs():
	return [s for s in input().split()]

def getStr():
	return input()

def listStr():
	return list(input())
MOD = 10 ** 9 + 7
t = int(input())
p = 10 ** 9 + 7

def ncr_util():
	inv[0] = inv[1] = 1
	fact[0] = fact[1] = 1
	for i in range(2, 300001):
		inv[i] = inv[i % p] * (p - p // i) % p
	for i in range(1, 300001):
		inv[i] = inv[i - 1] * inv[i] % p
		fact[i] = fact[i - 1] * i % p

def solve():
	if (l - 0.5) * 2 >= r:
		print('YES')
	else:
		print('NO')
for _ in range(t):
	(l, r) = map(int, input().split())
	solve()


t = int(input())
inputs = []
for i in range(0, t):
	inputs.append([int(p) for p in input().split(' ')])
for i in inputs:
	l = i[0]
	r = i[1]
	boo = False
	if 2 * l > r:
		print('YES')
	else:
		print('NO')


from __future__ import division, print_function
from fractions import Fraction
import sys
import os
from io import BytesIO, IOBase
from itertools import *
import bisect
from heapq import *
from math import ceil, floor
from copy import *
from collections import deque, defaultdict
from collections import Counter as counter
from itertools import combinations
from itertools import permutations as permutate
from bisect import bisect_left as bl
from operator import *
from bisect import bisect_right as br
from bisect import bisect
BUFSIZE = 8192
from sys import stderr

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
				continue
			stack.pop()
			if not stack:
				break
			to = stack[-1].send(to)
		return to
	return wrapped_func
mod = 1000000007

def inp():
	return sys.stdin.readline().rstrip('\r\n')

def out(var):
	sys.stdout.write(str(var))

def lis():
	return list(map(int, inp().split()))

def stringlis():
	return list(map(str, inp().split()))

def sep():
	return map(int, inp().split())

def strsep():
	return map(str, inp().split())

def fsep():
	return map(float, inp().split())

def nextline():
	out('\n')

def testcase(t):
	for p in range(t):
		solve()

def pow(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res
from functools import reduce

def factors(n):
	return set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0)))

def gcd(a, b):
	if a == b:
		return a
	while b > 0:
		(a, b) = (b, a % b)
	return a

def prefix_sum(ar):
	return list(accumulate(ar))

def suffix_sum(ar):
	return list(accumulate(ar[::-1]))[::-1]

def N():
	return int(inp())
from collections import defaultdict

def numberOfSetBits(i):
	i = i - (i >> 1 & 1431655765)
	i = (i & 858993459) + (i >> 2 & 858993459)
	return ((i + (i >> 4) & 252645135) * 16843009 & 4294967295) >> 24

def solve():
	(l, r) = sep()
	if 2 * l >= r + 1:
		print('YES')
	else:
		print('NO')
testcase(int(inp()))


def read_int() -> int:
	return int(input())

def read_ints():
	return map(int, input().split(' '))

def test_case() -> None:
	(left, right) = read_ints()
	print('YES' if left * 2 > right else 'NO')
for _ in range(read_int()):
	test_case()


for _ in range(int(input())):
	(a, b) = map(int, input().split())
	mi = min(a, b)
	ma = max(a, b)
	if mi <= int(b / 2):
		print('NO')
	else:
		print('YES')


import sys
from collections import defaultdict as dd
from collections import Counter as cc
from queue import Queue
import math
import itertools
try:
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
except:
	pass
input = lambda : sys.stdin.buffer.readline().rstrip()
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	q = 2 * (2 * l) / 3
	if (r + 1) / 2 <= l:
		print('YES')
	elif r < q:
		print('YES')
	else:
		print('NO')


for t in range(int(input())):
	(l, r) = map(int, input().split())
	if l / r <= 0.5:
		print('NO')
	else:
		print('YES')


for iii in range(int(input())):
	(l, r) = list(map(int, input().split()))
	tmp = r + 1
	if r // 2 >= l:
		print('NO')
	else:
		print('YES')


import copy
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))

def input():
	return sys.stdin.readline().rstrip('\r\n')
mo = 19260817

def exgcd(a, b):
	if not b:
		return (1, 0)
	(y, x) = exgcd(b, a % b)
	y -= a // b * x
	return (x, y)

def getinv(a, m):
	(x, y) = exgcd(a, m)
	return -1 if x == 1 else x % m

def comb(n, b):
	res = 1
	b = min(b, n - b)
	for i in range(b):
		res = res * (n - i) * getinv(i + 1, mo) % mo
	return res % mo
for _ti in range(int(input())):
	(l, r) = map(int, input().split())
	if r < l * 2:
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout
for t in range(int(stdin.readline())):
	(a, b) = map(int, stdin.readline().split())
	if a == b == 1:
		print('YES')
		continue
	check = (b + 1) / 2
	if a >= check:
		print('YES')
	else:
		print('NO')


import sys
for i in range(0, int(sys.stdin.readline())):
	nums = sys.stdin.readline().split()
	a = int(nums[0])
	b = int(nums[1])
	if 2 * a > b:
		sys.stdout.write('YES\n')
	else:
		sys.stdout.write('NO\n')


def solution(l, r):
	return 'YES' if l > r - l else 'NO'
test_num = int(input())
tests = []
for _ in range(test_num):
	tests.append(list(map(int, input().split())))
for test in tests:
	print(solution(test[0], test[1]))


import os
import math
import statistics
true = True
false = False
from functools import reduce
is_dev = 'vscode' in os.environ
if is_dev:
	inF = open('in.txt', 'r')
	outF = open('out.txt', 'w')

def ins():
	return list(map(int, input_().split(' ')))

def inss():
	return list(input_().split(' '))

def input_():
	if is_dev:
		return inF.readline()[:-1]
	else:
		return input()

def ranin():
	return range(int(input_()))

def print_(data):
	if is_dev:
		outF.write(str(data) + '\n')
	else:
		print(data)
epsilon = 1e-07

def optimize(arr):
	arr_median = statistics.median(arr)
	return sum((abs(arr_median - ai) for ai in arr))
for _ in ranin():
	(l, r) = ins()
	if l == r:
		print_('YES')
		continue
	first_test = r // 2 + 1
	if l % first_test >= first_test / 2 and r % first_test >= l % first_test and (l > first_test):
		print_('YES')
		continue
	second_test = r + 1
	if l % second_test >= second_test / 2:
		print_('YES')
		continue
	print_('NO')
if is_dev:
	outF.close()

	def compare_file():
		print(open('out.txt', 'r').read() == open('outactual.txt', 'r').read())
	compare_file()


number_of_testcase = int(input())
for testcase in range(number_of_testcase):
	key_input = input().strip().split(' ')
	l = int(key_input[0])
	r = int(key_input[1])
	if r % l >= r - l:
		print('YES')
	else:
		print('NO')


import sys, os
import heapq, functools, collections
import math, random
from collections import Counter, defaultdict

def solve_(a, b):
	if b / 2 < a:
		return 'YES'
	return 'NO'

def console(*args):
	print('\x1b[36m', *args, '\x1b[0m', file=sys.stderr)
	pass
if os.path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

	def console(*args):
		pass

def solve(*args):
	console('----- solving ------')
	console(*args)
	console('----- ------- ------')
	return solve_(*args)
if True:
	inp = iter(sys.stdin.buffer.readlines())
	input = lambda : next(inp)
else:
	input = sys.stdin.buffer.readline
for case_num in range(int(input())):
	(a, b) = list(map(int, input().split()))
	res = solve(a, b)
	print(res)


import os, sys
from io import IOBase, BytesIO
py2 = round(0.5)
if py2:
	from future_builtins import ascii, filter, hex, map, oct, zip
	range = xrange
BUFSIZE = 8192

class FastIO(BytesIO):
	newlines = 0

	def __init__(self, file):
		self._file = file
		self._fd = file.fileno()
		self.writable = 'x' in file.mode or 'w' in file.mode
		self.write = super(FastIO, self).write if self.writable else None

	def _fill(self):
		s = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
		self.seek((self.tell(), self.seek(0, 2), super(FastIO, self).write(s))[0])
		return s

	def read(self):
		while self._fill():
			pass
		return super(FastIO, self).read()

	def readline(self):
		while self.newlines == 0:
			s = self._fill()
			self.newlines = s.count(b'\n') + (not s)
		self.newlines -= 1
		return super(FastIO, self).readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.getvalue())
			(self.truncate(0), self.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		if py2:
			self.write = self.buffer.write
			self.read = self.buffer.read
			self.readline = self.buffer.readline
		else:
			self.write = lambda s: self.buffer.write(s.encode('ascii'))
			self.read = lambda : self.buffer.read().decode('ascii')
			self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
import sys

class ostream:

	def __lshift__(self, a):
		sys.stdout.write(str(a))
		return self
cout = ostream()
endl = '\n'

def get_input(a=str):
	return a(input())

def get_int_input():
	return get_input(int)

def get_input_arr(a):
	return list(map(a, input().split()))

def get_int_input_arr():
	return get_input_arr(int)

def solve():
	t = get_int_input()
	for _ in range(t):
		(l, r) = get_int_input_arr()
		k = 2 * l
		if r <= 2 * l - 1:
			cout << 'YES' << endl
		else:
			cout << 'NO' << endl

def main():
	solve()
main()


t = int(input())
while t > 0:
	(l, r) = map(int, input().split())
	print('YNEOS'[r >= l * 2::2])
	t -= 1


for i in range(int(input())):
	(n, m) = map(int, input().split())
	p = 'NO'
	if 2 * n > m:
		p = 'YES'
	print(p)


from __future__ import division, print_function
import os, sys
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip

def ii():
	return int(input())

def si():
	return input()

def mi():
	return map(int, input().strip().split(' '))

def msi():
	return map(str, input().strip().split(' '))

def li():
	return list(mi())

def dmain():
	sys.setrecursionlimit(1000000)
	threading.stack_size(1024000)
	thread = threading.Thread(target=main)
	thread.start()
import sys
input = sys.stdin.readline
scanner = lambda : int(input())
string = lambda : input().rstrip()
get_list = lambda : list(read())
read = lambda : map(int, input().split())
get_float = lambda : map(float, input().split())

def ceil(x):
	if x != int(x):
		x = int(x) + 1
	return x

def factorial(x, m):
	val = 1
	while x > 0:
		val = val * x % m
		x -= 1
	return val

def fact(x):
	val = 1
	while x > 0:
		val *= x
		x -= 1
	return val

def swaparr(arr, a, b):
	temp = arr[a]
	arr[a] = arr[b]
	arr[b] = temp

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def lcm(a, b):
	return a * b // math.gcd(a, b)

def is_integer(n):
	return math.ceil(n) == math.floor(n)

def nCr(n, k):
	if k > n:
		return 0
	if k > n - k:
		k = n - k
	res = 1
	for i in range(k):
		res = res * (n - i)
		res = res / (i + 1)
	return int(res) % MOD

def comb(n, x):
	(a, b) = (1, 1)
	for i in range(1, x + 1):
		a *= n + 1 - i
		b *= i
	return a // b % MOD

def primefs(n):
	primes = {}
	while n % 2 == 0 and n > 0:
		primes[2] = primes.get(2, 0) + 1
		n = n // 2
	for i in range(3, int(n ** 0.5) + 2, 2):
		while n % i == 0 and n > 0:
			primes[i] = primes.get(i, 0) + 1
			n = n // i
	if n > 2:
		primes[n] = primes.get(n, 0) + 1
	return primes

def power(x, y, p):
	if y == 0:
		return 1
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def swap(a, b):
	temp = a
	a = b
	b = temp
	return (a, b)

def find(x, link):
	p = x
	while p != link[p]:
		p = link[p]
	while x != p:
		nex = link[x]
		link[x] = p
		x = nex
	return p

def union(x, y, link, size):
	x = find(x, link)
	y = find(y, link)
	if size[x] < size[y]:
		(x, y) = swap(x, y)
	if x != y:
		size[x] += size[y]
		link[y] = x

def sieve(n):
	prime = [True for i in range(n + 1)]
	(prime[0], prime[1]) = (False, False)
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	return prime

def phi(n):
	result = n
	p = 2
	while p * p <= n:
		if n % p == 0:
			while n % p == 0:
				n = n // p
			result = result * (1.0 - 1.0 / float(p))
		p = p + 1
	if n > 1:
		result = result * (1.0 - 1.0 / float(n))
	return int(result)

def is_prime(n):
	if n == 0:
		return False
	if n == 1:
		return True
	for i in range(2, int(n ** (1 / 2)) + 1):
		if not n % i:
			return False
	return True

def next_prime(n, primes):
	while primes[n] != True:
		n += 1
	return n
MAXN = int(100000.0 + 5)

def spf_sieve():
	spf[1] = 1
	for i in range(2, MAXN):
		spf[i] = i
	for i in range(4, MAXN, 2):
		spf[i] = 2
	for i in range(3, ceil(MAXN ** 0.5), 2):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i
spf = [0 for i in range(MAXN)]

def factoriazation(x):
	res = []
	for i in range(2, int(x ** 0.5) + 1):
		while x % i == 0:
			res.append(i)
			x //= i
	if x != 1:
		res.append(x)
	return res

def factors(n):
	res = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			res.append(i)
			res.append(n // i)
	return list(set(res))

def int_array():
	return list(map(int, input().strip().split()))

def float_array():
	return list(map(float, input().strip().split()))

def str_array():
	return input().strip().split()

def binary_search(low, high, w, h, n):
	while low < high:
		mid = low + (high - low) // 2
		if check(mid, w, h, n):
			low = mid + 1
		else:
			high = mid
	return low

def check(moves, n):
	val = (moves + 1) // 2
	rem = moves - val
	sol = (val + 1) * (rem + 1)
	return sol < n

def sortSecond(val):
	return val[1]
MOD = int(1000000000.0) + 7
CMOD = 998244353
INF = float('inf')
NINF = -float('inf')
small = 'abcdefghijklmnopqrstuvwxyz'
large = small.upper()
from itertools import permutations
import math
import bisect as bis
import random
import sys
import collections as collect
import functools as fnt
from decimal import Decimal

def solve():
	(a, b) = read()
	if b >= 2 * a:
		print('NO')
	else:
		print('YES')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
t = scanner()
for i in range(t):
	solve()


MOD = 1000000007
from collections import defaultdict as dd, Counter, deque

def si():
	return input()

def ii():
	return int(input())

def li():
	return list(map(int, input().split()))

def mi():
	return map(int, input().split())

def out(v):
	print(v)

def spout():
	print(v, end=' ')

def d2b(n):
	return bin(n).replace('0b', '')

def twod(n, m, num):
	return [[num for x in range(m)] for y in range(n)]

def vow():
	return ['a', 'e', 'i', 'o', 'u']

def let():
	return [chr(i) for i in range(97, 123)]

def gcd(x, y):
	while y:
		(x, y) = (y, x % y)
	return x

def ispow2(x):
	return x and (not x & x - 1)

def prime_factors(n):
	i = 2
	factors = []
	while i * i <= n:
		if n % i:
			i += 1
		else:
			n //= i
			factors.append(i)
	if n > 1:
		factors.append(n)
	return list(factors)
t = ii()
while t:
	t -= 1
	(l, r) = mi()
	if r < l * 2:
		print('YES')
	else:
		print('NO')


a = int(input())
for i in range(a):
	b = [int(j) for j in input().split()]
	if b[0] > b[1] // 2:
		print('YES')
	else:
		print('NO')


n = int(input())
for i in range(n):
	(l, r) = list(map(int, input().split()))
	r1 = (l + r) // 2
	c1 = l % (r + 1)
	c2 = (r + 1) / 2
	if c1 >= c2:
		print('YES')
	else:
		print('NO')


for t in range(int(input())):
	(a, b) = list(map(int, input().split()))
	if a % (b + 1) >= (b + 1) / 2 and b % (b + 1) >= (b + 1) / 2:
		print('YES')
	else:
		print('NO')


from collections import deque
from collections import OrderedDict
from queue import PriorityQueue
from operator import attrgetter
import math
import sys
import os
import threading
import bisect
import operator
import queue
import heapq
from atexit import register
from io import BytesIO
import io
from sys import stdin, stdout
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
input = lambda : sys.stdin.readline().rstrip('\r\n')
for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if math.ceil((r + 1) / 2) <= l:
		print('YES')
	else:
		print('NO')


def main():
	t = int(input())
	ans = []
	for i in range(t):
		(l, r) = map(int, input().split())
		a = r + 1
		if l >= a / 2:
			ans.append('YES')
		else:
			ans.append('NO')
	print('\n'.join(ans))
main()


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if l * 2 > r:
		print('YES')
		continue
	print('NO')


from sys import stdin, stdout
import math
import heapq
import collections
input = stdin.readline

def inputnum():
	return int(input())

def inputnums():
	return map(int, input().split())

def inputlist():
	return list(map(int, input().split()))

def inputstring():
	return [x for x in input()]

def inputstrings():
	return [x for x in input().split()]

def inputstringnum():
	return [ord(x) - ord('a') for x in input()]

def inputmatrixchar(rows):
	arr2d = [[j for j in input().strip()] for i in range(rows)]
	return arr2d

def inputmatrixint(rows):
	arr2d = []
	for _ in range(rows):
		arr2d.append([int(i) for i in input().split()])
	return arr2d
t = int(input())
for q in range(t):
	(l, r) = inputnums()
	if r < l * 2:
		print('YES')
		continue
	print('NO')


def ii():
	return int(input())

def mi():
	return map(int, input().split())
for _ in range(ii()):
	(l, r) = mi()
	print(['NO', 'YES'][2 * l > r])


for _ in range(int(input())):
	(l, r) = map(int, input().split())
	if l == 1 and r > 1:
		print('NO')
	elif l > 1 and r > 1:
		x = r + 1
		z = r + 1
		z = z / 2
		if int(z) > z:
			z = int(z) + 1
		else:
			z = z
		if l % x < z:
			print('NO')
		else:
			print('YES')
	else:
		print('YES')


t = int(input())
for i in range(t):
	s = input()
	s1 = s.split()
	if int(s1[0]) > int(s1[1]) / 2:
		print('YES')
	else:
		print('NO')


from collections import Counter
import string
import math
import sys
from fractions import Fraction

def array_int():
	return [int(i) for i in sys.stdin.readline().split()]

def vary(arrber_of_variables):
	if arrber_of_variables == 1:
		return int(sys.stdin.readline())
	if arrber_of_variables >= 2:
		return map(int, sys.stdin.readline().split())

def makedict(var):
	return dict(Counter(var))

def printDivisors(n):
	divisors = []
	i = 1
	while i <= math.sqrt(n):
		if n % i == 0:
			if n // i == i:
				divisors.append(i)
			else:
				divisors.extend((i, n // i))
		i = i + 1
	return divisors

def countTotalBits(num):
	binary = bin(num)[2:]
	return len(binary)

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	i = 5
	while i * i <= n:
		if n % i == 0 or n % (i + 2) == 0:
			return False
		i = i + 6
	return True
for _ in range(vary(1)):
	(l, r) = vary(2)
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


def main():
	for _ in range(int(input())):
		(L, R) = list(map(int, input().split()))
		X = 2 * L
		if L % X >= X / 2 and R < X:
			print('YES')
		else:
			print('NO')
main()


t = int(input())
results = []
for i in range(t):
	[l, r] = [int(j) for j in input().split(' ')]
	res = 'YES' if 2 * l > r else 'NO'
	results.append(res)
for i in results:
	print(i)


a = int(input())
for i in range(a):
	(l, r) = [int(each) for each in input().split()]
	if l * 2 > r:
		print('YES')
	else:
		print('NO')


t = int(input())
for q in range(t):
	(a, b) = map(int, input().split())
	if 2 * a > b:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def list2d(a, b, c):
	return [[c] * b for i in range(a)]

def list3d(a, b, c, d):
	return [[[d] * c for j in range(b)] for i in range(a)]

def list4d(a, b, c, d, e):
	return [[[[e] * d for j in range(c)] for j in range(b)] for i in range(a)]

def ceil(x, y=1):
	return int(-(-x // y))

def Yes():
	print('Yes')

def No():
	print('No')

def YES():
	print('YES')

def NO():
	print('NO')
INF = 10 ** 18
MOD = 10 ** 9 + 7
Ri = lambda : [int(x) for x in sys.stdin.readline().split()]
ri = lambda : sys.stdin.readline().strip()
for _ in range(int(ri())):
	(a, b) = Ri()
	half = (b + 1) / 2
	if a >= half:
		YES()
	else:
		NO()


def readGenerator():
	while True:
		tokens = input().split(' ')
		for t in tokens:
			yield t
reader = readGenerator()

def readWord():
	return next(reader)

def readInt():
	return int(next(reader))

def readFloat():
	return float(next(reader))

def readLine():
	return input()

def solve(l, r):
	if 2 * l <= r:
		return 'NO'
	return 'YES'
t = readInt()
for _ in range(t):
	l = readInt()
	r = readInt()
	print(solve(l, r))


import sys
import time
import os
from math import sqrt, log, log2, log10, gcd, floor, pow, sin, cos, tan, pi, inf, factorial
from copy import copy, deepcopy
from sys import exit, stdin, stdout
from collections import Counter, defaultdict, deque
from itertools import permutations
import heapq
from bisect import bisect_left as bl
from bisect import bisect_right as br
from bisect import bisect
mod = 1000000007
iinp = lambda : int(sys.stdin.readline())
inp = lambda : sys.stdin.readline().strip()
strl = lambda : list(inp().strip().split(' '))
intl = lambda : list(map(int, inp().split(' ')))
mint = lambda : map(int, inp().split())
flol = lambda : list(map(float, inp().split(' ')))
flush = lambda : stdout.flush()

def permute(nums):

	def fun(arr, nums, cur, v):
		if len(cur) == len(nums):
			arr.append(cur.copy())
		i = 0
		while i < len(nums):
			if v[i]:
				i += 1
				continue
			else:
				cur.append(nums[i])
				v[i] = 1
				fun(arr, nums, cur, v)
				cur.pop()
				v[i] = 0
				i += 1
		return arr
	res = []
	nums.sort()
	v = [0] * len(nums)
	return fun(res, nums, [], v)

def subsets(res, index, arr, cur):
	res.append(cur.copy())
	for i in range(index, len(arr)):
		cur.append(arr[i])
		subsets(res, i + 1, arr, cur)
		cur.pop()
	return res

def sieve(N):
	root = int(sqrt(N))
	primes = [1] * (N + 1)
	(primes[0], primes[1]) = (0, 0)
	for i in range(2, root + 1):
		if primes[i]:
			for j in range(i * i, N + 1, i):
				primes[j] = 0
	return primes

def bs(arr, l, r, x):
	if x < arr[0] or x > arr[len(arr) - 1]:
		return -1
	while l <= r:
		mid = l + (r - l) // 2
		if arr[mid] == x:
			return mid
		elif arr[mid] < x:
			l = mid + 1
		else:
			r = mid - 1
	return -1

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	p = int(sqrt(n))
	for i in range(5, p + 1, 6):
		if n % i == 0 or n % (i + 2) == 0:
			return False
	return True

def solve():
	(l, r) = mint()
	a = 1
	print('YES') if 2 * l > r else print('NO')
start_time = time.time()
for _ in range(iinp()):
	solve()


import math
t = int(input())
while t:
	(l, r) = [int(x) for x in input().split()]
	if l > r / 2:
		print('YES')
	else:
		print('NO')
	t -= 1


t = int(input())
for case in range(t):
	(l, r) = [int(x) for x in input().split(' ')]
	if r >= 2 * l:
		print('NO')
	else:
		print('YES')


tests = int(input())
for test in range(tests):
	(l, r) = map(int, input().split())
	a = r + 2
	if l >= a // 2:
		print('YES')
	else:
		print('NO')


def market(a, b):
	if b < 2 * a:
		return 'YES'
	else:
		return 'NO'
t = int(input())
for i in range(t):
	(a, b) = map(int, input().split())
	print(market(a, b))


T = int(input())
for _ in range(0, T):
	(a, b) = map(int, input().split())
	c = b + 1
	if a >= c / 2 and b >= c / 2:
		print('YES')
	else:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
_str = str
BUFSIZE = 8192

def str(x=b''):
	return x if type(x) is bytes else _str(x).encode()

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def inp():
	return sys.stdin.readline().rstrip()

def mpint():
	return map(int, inp().split(' '))

def itg():
	return int(inp())

def solve():
	(a, b) = mpint()
	return b - a < a

def main():
	for _ in range(itg()):
		print('YES' if solve() else 'NO')
DEBUG = 0
URL = ''
if DEBUG == 1:
	import requests
	from ACgenerator.Y_Test_Case_Runner import TestCaseRunner
	runner = TestCaseRunner(main, URL)
	inp = runner.input_stream
	print = runner.output_stream
	runner.checking()
elif DEBUG == 2:
	main()
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
	main()


def solve():
	(a, b) = map(int, input().strip().split())
	if b / a >= 2:
		print('NO')
	else:
		print('YES')
t = int(input())
for _ in range(t):
	solve()


import sys
sys.setrecursionlimit(10 ** 5)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep='\n')

def II():
	return int(sys.stdin.buffer.readline())

def MI():
	return map(int, sys.stdin.buffer.readline().split())

def LI():
	return list(map(int, sys.stdin.buffer.readline().split()))

def LLI(rows_number):
	return [LI() for _ in range(rows_number)]

def BI():
	return sys.stdin.buffer.readline().rstrip()

def SI():
	return sys.stdin.buffer.readline().rstrip().decode()
for _ in range(II()):
	(l, r) = MI()
	a = r + 1
	if l % a * 2 >= a:
		print('YES')
	else:
		print('NO')


from sys import stdin, stdout
from collections import *
from math import *
st = lambda : list(stdin.readline().strip())
li = lambda : list(map(int, stdin.readline().split()))
mp = lambda : map(int, stdin.readline().split())
inp = lambda : int(stdin.readline())
pr = lambda n: stdout.write(str(n) + '\n')
mod = 1000000007
INF = float('inf')

def solve():
	(a, b) = mp()
	if a << 1 <= b:
		pr('NO')
	else:
		pr('YES')
for _ in range(inp()):
	solve()


def main():
	n = int(input())
	for _ in range(n):
		(a, b) = map(int, input().split())
		if a <= b / 2:
			print('NO')
		else:
			print('YES')
main()


def main():
	(l, r) = map(int, input().split())
	a = r + 1
	if l >= a / 2:
		print('YES')
	else:
		print('NO')
rw = int(input())
for wewq in range(rw):
	main()


for i in range(0, int(input())):
	a = list(map(int, input().split()))
	b = a[0]
	d = a[1]
	if b * 2 > d:
		print('YES')
	else:
		print('NO')


import math
t = int(input())
for _ in range(t):
	(l, r) = input().split()
	(l, r) = (int(l), int(r))
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


from pprint import pprint
import sys

def do():
	(l, r) = map(int, input().split())
	x = r + 1
	if x / 2 <= l:
		print('YES')
		return
	print('NO')
q = int(input())
for _ in range(q):
	do()


def check(a):
	q = 0
	for i in (a[0] // 2, a[0]):
		if a[0] // i == a[1] // i and a[0] % i >= i / 2:
			q = i
	return q
for i in range(int(input())):
	a = [int(x) for x in input().split()]
	if a[0] == 1 and a[1] == 1:
		print('YES')
	elif a[0] == 1 and a[1] > 1:
		print('NO')
	elif (a[1] + 1) / 2 > a[0] and check(a) == 0:
		print('NO')
	else:
		print('YES')


for _ in range(int(input())):
	l = list(map(int, input().split()))
	if l[0] << 1 > l[1]:
		print('YES')
	else:
		print('NO')


import math
try:
	t = int(input())
	for i in range(t):
		(n, m) = map(int, input().split())
		if 2 * n > m:
			print('YES')
		else:
			print('NO')
except:
	pass


test = int(input())
for _ in range(test):
	(l, r) = map(int, input().split())
	v = l * 2
	if r < v:
		print('YES')
	else:
		print('NO')


_39 = '1445b'
_40 = '1445a'
_41 = '1437a'
k = []
for i in range(int(input())):
	(l, r) = map(int, input().split())
	if 2 * l > r:
		k.append('YES')
	else:
		k.append('NO')
for i in k:
	print(i)


t = int(input())
for i in range(t):
	a = input().split()
	if int(a[1]) >= int(a[0]) * 2:
		print('NO')
	else:
		print('YES')


from sys import stdin, stdout
import math, bisect
from collections import Counter, deque, defaultdict
L = lambda : list(map(int, stdin.readline().strip().split()))
M = lambda : map(int, stdin.readline().strip().split())
I = lambda : int(stdin.readline().strip())
S = lambda : stdin.readline().strip()
C = lambda : stdin.readline().strip().split()

def pr(a):
	print(' '.join(list(map(str, a))))

def solve():
	(l, r) = M()
	if 2 * l <= r:
		print('NO')
	else:
		print('YES')
for _ in range(I()):
	solve()


t = int(input())
for _ in range(t):
	(l, r) = [int(x) for x in input().split()]
	print('YES' if r < l << 1 else 'NO')


import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush
from math import *
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction
import copy
import time
starttime = time.time()
mod = int(pow(10, 9) + 7)
mod2 = 998244353

def data():
	return sys.stdin.readline().strip()

def out(*var, end='\n'):
	sys.stdout.write(' '.join(map(str, var)) + end)

def L():
	return list(sp())

def sl():
	return list(ssp())

def sp():
	return map(int, data().split())

def ssp():
	return map(str, data().split())

def l1d(n, val=0):
	return [val for i in range(n)]

def l2d(n, m, val=0):
	return [l1d(n, val) for j in range(m)]
try:
	sys.stdin = open('input.txt', 'r')
except:
	pass

def pmat(A):
	for ele in A:
		print(*ele, end='\n')

def seive():
	prime = [1 for i in range(10 ** 6 + 1)]
	prime[0] = 0
	prime[1] = 0
	for i in range(10 ** 6 + 1):
		if prime[i]:
			for j in range(2 * i, 10 ** 6 + 1, i):
				prime[j] = 0
	return prime
for _ in range(L()[0]):
	(l, r) = L()
	if 2 * l <= r:
		print('NO')
	else:
		print('YES')
endtime = time.time()


t = int(input())
for i in range(t):
	(l, r) = list(map(int, input().split()))
	a = max(l, r)
	b = min(l, r)
	if a + 1 > 2 * b:
		print('NO')
	else:
		print('YES')


from collections import Counter
from collections import OrderedDict
from collections import defaultdict
import bisect

def freq_count(mylist):
	return Counter(mylist)
t = int(input())
for _ in range(t):
	(l, r) = map(int, input().split())
	if l * 2 <= r:
		print('NO')
	else:
		print('YES')


import sys
import math as mt
import collections as cc
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
for tc in range(int(input())):
	(l, r) = I()
	if r < 2 * l:
		print('YES')
	else:
		print('NO')


import collections
import math
from itertools import permutations as p
for t in range(int(input())):
	(l, r) = map(int, input().split())
	if l <= r // 2:
		print('NO')
	else:
		print('YES')


from os import path
import sys
from heapq import heappush, heappop
from functools import cmp_to_key as ctk
from collections import deque, defaultdict as dd
from bisect import bisect, bisect_left, bisect_right, insort, insort_left, insort_right
from itertools import permutations
from datetime import datetime
from math import ceil, sqrt, log, gcd

def ii():
	return int(input())

def si():
	return input().rstrip()

def mi():
	return map(int, input().split())

def li():
	return list(mi())
abc = 'abcdefghijklmnopqrstuvwxyz'
mod = 1000000007
inf = float('inf')
vow = ['a', 'e', 'i', 'o', 'u']
(dx, dy) = ([-1, 1, 0, 0], [0, 0, 1, -1])

def bo(i):
	return ord(i) - ord('a')
file = 1

def solve():
	for _ in range(ii()):
		(l, r) = mi()
		if r < 2 * l:
			print('YES')
		else:
			print('NO')
if file:
	if path.exists('input.txt'):
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	else:
		input = sys.stdin.readline
solve()


class Solution:

	def rotate(self, l, r):
		if r == 0:
			return 'NO'
		m = l / r
		if m <= 0.5:
			return 'NO'
		else:
			return 'YES'
solution = Solution()
n = int(input())
for _ in range(n):
	(l, r) = map(int, input().split())
	print(solution.rotate(l, r))


import sys
import math

def II():
	return int(sys.stdin.readline())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def MI():
	return map(int, sys.stdin.readline().split())

def SI():
	return sys.stdin.readline().strip()
t = II()
for j in range(t):
	(a, b) = MI()
	if max(a, b) < 2 * min(a, b):
		print('YES')
	else:
		print('NO')


t = int(input())
t1 = t
ars = []
while t != 0:
	t -= 1
	(l, r) = map(int, input().split())
	a = r + 1
	if l % a < a / 2:
		ars.append('NO')
	if l % a >= a / 2:
		ars.append('YES')
for i in range(0, t1):
	print(ars[i])


t = int(input())
for _ in range(t):
	(x, y) = [int(k) for k in input().split(' ')]
	if 2 * x > y:
		print('YES')
	else:
		print('NO')