import java.io.*; import java.util.*; public class Solution { public static void main(String[] args) { /* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */ Scanner sc=new Scanner(System.in); int q,x,y,n,x1,y1; boolean d; q=sc.nextInt(); for(int i=1;i<=q;i++) { n=sc.nextInt(); if(n==1) System.out.println("YES"); else { x=sc.nextInt(); y=sc.nextInt(); d=true; for(int j=1;j