Recently Petya walked in the forest and found a magic stick.

Since Petya really likes numbers, the first thing he learned was spells for changing numbers. So far, he knows only two spells that can be applied to a positive integer:   If the chosen number $a$ is even, then the spell will turn it into $\frac{3a}{2}$;  If the chosen number $a$ is greater than one, then the spell will turn it into $a-1$. 

Note that if the number is even and greater than one, then Petya can choose which spell to apply.

Petya now has only one number $x$. He wants to know if his favorite number $y$ can be obtained from $x$ using the spells he knows. The spells can be used any number of times in any order. It is not required to use spells, Petya can leave $x$ as it is.


-----Input-----

The first line contains single integer $T$ ($1 \le T \le 10^4$) — the number of test cases. Each test case consists of two lines.

The first line of each test case contains two integers $x$ and $y$ ($1 \le x, y \le 10^9$) — the current number and the number that Petya wants to get.


-----Output-----

For the $i$-th test case print the answer on it — YES if Petya can get the number $y$ from the number $x$ using known spells, and NO otherwise.

You may print every letter in any case you want (so, for example, the strings yEs, yes, Yes and YES will all be recognized as positive answer).


-----Example-----
Input
7
2 3
1 1
3 6
6 8
1 2
4 1
31235 6578234

Output
YES
YES
NO
YES
NO
YES
YES

Difficulty: interview

Starter code:

Solutions:
t = int(input())

for i in range(t):
	a, b = map(int, input().split())

	if a == 1:
		if b == 1:
			print('YES')
		else:
			print('NO')
		continue

	if a <= 3:
		if b <= 3:
			print('YES')
		else:
			print('NO')
		continue

	print('YES')

# Contest: Educational Codeforces Round 76 (Rated for Div. 2) (https://codeforces.com/contest/1257)
# Problem: B: Magic Stick (https://codeforces.com/contest/1257/problem/B)

def rint():
    return int(input())


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


t = rint()
for _ in range(t):
    x, y = rints()
    if x == 1:
        r = y == 1
    elif x == 2 or x == 3:
        r = y <= 3
    else:
        r = True
    print('YES' if r else 'NO')


def f(x):
    return (x > 1) + (x > 3)


def main():
    for _ in range(int(input())):
        x, y = list(map(int, input().split()))
        print("YES" if f(x) >= f(y) else "NO")


main()


import random


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


def get_int():
    return int(input())


def get_int_list():
    return list(get_many_ints())


def prog():
    x, y = get_many_ints()
    if x >= 4:
        print("YES")
        return
    ok = (x == 1 and y == 1) or (x in [2, 3] and y <= 3)
    print("YES" if ok else "NO")


q = get_int()
for _ in range(q):
    prog()


n=int(input())
for i in range(n):
    x,y=[int(x) for x in input().split(' ')]
    if x == 1:
        if y == 1:
            print('YES')
        else:
            print('NO')
    elif x in [2,3]:
        if y in [1,2,3]:
            print('YES')
        else:
            print('NO')
    else:
        print('YES')


n = int(input())
for i in range(n):
	a, b = list(map(int, input().split()))
	if a == 2:
		a = 3
	if a >= 4:
		print ("YES")
	else:
		if a >= b:
			print ("YES")
		else:
			print ("NO")


a = int(input())
for i in range(a):
    x, y = map(int, input().split())
    if x >= 4:
        print('YES')
    elif y <= x:
        print('YES')
    elif x == 2 and y == 3:
        print('YES')
    else:
        print('NO')

q = int(input())
for re in range(q):
	a, b = map(int,input().split())
	if a >=4:
		print("YES")
	else:
		if a == 1:
			if b == 1:
				print("YES")
			else:
				print("NO")
		if a == 2 or a == 3:
			if b in [1,2,3]:
				print("YES")
			else:
				print("NO")

import sys
input = sys.stdin.readline

t=int(input())

for testcases in range(t):
    x,y=list(map(int,input().split()))

    if x==1:
        if y==1:
            print("YES")
        else:
            print("NO")

    elif x<=3:
        if y<=3:
            print("YES")
        else:
            print("NO")

    else:
        print("YES")


t = int(input())
for i in range (t):
    a, b = list(map(int,input().split()))
    if a > 3:
        print("YES")
    elif a == 1:
        if b == 1:
            print("YES")
        else:
            print("NO")
    else:
        if b < 4:
            print("YES")
        else:
            print("NO")

def Y(f):
    if f:
        print('YES')
    else:
        print('NO')

n = int(input())
for _ in range(n):
    a,b = map(int,input().split())
    if a == 1:
        Y(b == 1)
    elif a <= 3:
        Y(b <= 3)
    else:
        Y(1)

T = int(input())

def solve(x, y):
    if x >= 4:
        return "YES"
    if x in [2, 3]:
        if y <= 3:
            return "YES"
    if x == 1:
        if y == 1:
            return "YES"
    return "NO"

for case in range(T):
    x, y = list(map(int, input().split()))
    print(solve(x, y))

'''
Created on 2019. 9. 21.

@author: kkhh88
'''
#q = int(input())
#x, y = map(int,input().split(' '))
#print (' '.join(list(map(str, s))))

q = int(input())

for i in range(q):
    x, y = list(map(int,input().split(' ')))
    
    if x >= y:
        print("YES")
        continue;

    while 1:

        
        if x % 2 == 0:
            x = (x * 3) // 2
        else:
            x = ((x - 1) * 3) // 2

        if x >= y:
            print("YES")
            break

        if x <= 3:
            print("NO")
            break

        


import sys, math
T = int(sys.stdin.readline())
for i in range(T):
	xy = sys.stdin.readline().split(" ")
	start = int(xy[0])
	target = int(xy[1])
	if start >= target or start >= 4 or (start == 2 and target == 3):
		print("YES")
	else:
		print("NO")


def main():
    answer = ""
    for query in range(int(input())):
        ans = None
        x,y = list(map(int,input().split(' ')))
        if x == 1:
            if y in {1}:
                ans = "YES"
            else:
                ans = "NO"
        elif x == 2 or x == 3:
            if y in {1,2,3}:
                ans = "YES"
            else:
                ans = "NO"
        else:
            ans = "YES"
        answer += str(ans) + "\n"
    print(answer)
main()


for _ in range(int(input())):
    x,y=list(map(int,input().split()))
    if x>=y:
        print("YES")
    elif x==2 and y>3:
        print("NO")
    elif x==1 and y>=2:
        print("NO")
    elif x==3 and y>3:
        print("NO")
    else:
        print("YES")


import sys
def I():
        return sys.stdin.readline().rstrip()

for _ in range(int(I())):
    x, y = list(map( int, I().split() ))
    print( "YES" if x > 3 or x == 1 and y == 1 or 2 <= x <= 3 and 1 <= y <= 3 else "NO" )


# 2 3  : 2 -> 3
# 1 1 : done
# 3 6 : 3 -> 2, 2 -> 3 går inte högre (nej)
# 6 8 : 6 -> 9 - JA
# 1 2 : nej
# 4 1 : ja
# 31235 6578234 : antagligen

# Om över 10 - verkar alltid gå

# 1 - bara 1
# 2 - 1, 2, 3
# 3 - 1, 2, 3
# 4 -> 6 -> 9 -> 8 -> 12 -> 18 -> 27 (verkar gå att fly)

def possible(x, y):
  if x >= 4: return True
  if x == 3: return y <= 3
  if x == 2: return y <= 3
  if x == 1: return y == 1

t = int(input())
for _ in range(t):
  a, b = [int(x) for x in input().split()]
  print("YES" if possible(a, b) else "NO")


t = int(input())
for i in range(t):
    (x,y) = [int(i) for i in input().split(" ")]
    if(x>3):
        print("YES")
    elif(x==3 or x==2):
        if(y==2 or y==1 or y==3):
            print("YES")
        else:
            print("NO")
    else:
        if(y==1):
            print("YES")
        else:
            print("NO")



import sys
import math

# sys.stdin = open("in.txt")
for _ in range(int(input())):
    a, b = map(int, input().split())
    if a <= 3:
        if a >= b <= 3 or a == 2 and b == 3:
            print("YES")
        else:
            print("NO")
    else:
        print("YES")

import math
from decimal import Decimal
import heapq
from collections import deque
def na():
	n = int(input())
	b = [int(x) for x in input().split()]
	return n,b
 
 
def nab():
	n = int(input())
	b = [int(x) for x in input().split()]
	c = [int(x) for x in input().split()]
	return n,b,c
 
 
def dv():
	n, m = list(map(int, input().split()))
	return n,m
 
 
def dva():
	n, m = list(map(int, input().split()))
	a = [int(x) for x in input().split()]
	b = [int(x) for x in input().split()]
	return n,m,b
 
 
def eratosthenes(n): 
	sieve = list(range(n + 1))
	for i in sieve:
		if i > 1:
			for j in range(i + i, len(sieve), i):
				sieve[j] = 0
	return sorted(set(sieve))
 
 
def lol(lst,k):
	k=k%len(lst)
	ret=[0]*len(lst)
	for i in range(len(lst)):
		if i+k<len(lst) and i+k>=0:
			ret[i]=lst[i+k]
		if i+k>=len(lst):
			ret[i]=lst[i+k-len(lst)]
		if i+k<0:
			ret[i]=lst[i+k+len(lst)]
	return(ret)
def nm():
	n = int(input())
	b = [int(x) for x in input().split()]
	m = int(input())
	c = [int(x) for x in input().split()]
	return n,b,m,c
 
 
def dvs():
	n = int(input())
	m = int(input())
	return n, m 
 
def fact(a, b):
	c = []
	ans = 0
	f = int(math.sqrt(a))
	for i in range(1, f + 1):
		if a % i == 0:
			c.append(i)
	l = len(c)
	for i in range(l):
		c.append(a // c[i])
	for i in range(len(c)):
		if c[i] <= b:
			ans += 1
	if a / f == f and b >= f:
		return ans - 1
	return ans
 
 
t = int(input())
for i in range(t):
	x, y = list(map(int, input().split()))
	if x >= y:
		print('YES')
		continue
	if x == 2 and y == 3:
		print('YES')
		continue
	elif x <= 3 and y > 3:
		print('NO')
		continue
	if x == 1:
		print('NO')
	else:
		print('YES')


def reach(x, y):
	if x == 1:
		return y == 1
	if x == 2 or x == 3:
		return y < 4

	return True

for _ in range(int(input())):
	if reach(*map(int, input().split())):
		print("YES")

	else:
		print("NO")