import java.util.Scanner;


public class Main {


	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	}

} import java.util.Scanner; Scanner java.util public class Main {


	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	}

} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	} main {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int num=sc.nextInt(); num sc.nextInt() sc.nextInt sc int i i a a b b c; c for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		} i=0; i=0 i 0 i<num i num i++ i++ i {
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		} {
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		} a = sc.nextInt() a sc.nextInt() sc.nextInt sc b = sc.nextInt() b sc.nextInt() sc.nextInt sc c = sc.nextInt() c sc.nextInt() sc.nextInt sc if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			} a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)) a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)) a*a == ((b*b) + (c*c)) a*a a a ((b*b) + (c*c)) (b*b) b b (c*c) c c b*b == ((a*a) + (c*c)) b*b b b ((a*a) + (c*c)) (a*a) a a (c*c) c c c*c == ((a*a) + (b*b)) c*c c c ((a*a) + (b*b)) (a*a) a a (b*b) b b {
				System.out.println("YES");
			} System.out.println("YES") System.out.println System.out System System.out "YES" {
				System.out.println("NO");
			} System.out.println("NO") System.out.println System.out System System.out "NO" String[] args args public class Main {


	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	}

} public class Main {


	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	}

} Main
import java.util.Scanner;


public class Main {


	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		
		Scanner sc = new Scanner(System.in);
		
		int num=sc.nextInt();
		int i,a,b,c;
		
		
		
		
		
		for(i=0;i<num;i++){
			a = sc.nextInt();
			b = sc.nextInt();
			c = sc.nextInt();
			
			if(a*a == ((b*b) + (c*c)) || b*b == ((a*a) + (c*c)) || c*c == ((a*a) + (b*b)))
			{
				System.out.println("YES");
			}
			else
			{
				System.out.println("NO");
			}
		}
	}

}