import java.util.Scanner;
class Main{
    public static void main(String[] a){
		int num1[] = new int[1000];
		int num2[] = new int[1000];
		int num3[] = new int[1000];
		int num,i = 0;
		Scanner scanner = new Scanner(System.in);
		num = Integer.parseInt(scanner.next());
		for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		}
		scanner.close();
    }
} import java.util.Scanner; Scanner java.util class Main{
    public static void main(String[] a){
		int num1[] = new int[1000];
		int num2[] = new int[1000];
		int num3[] = new int[1000];
		int num,i = 0;
		Scanner scanner = new Scanner(System.in);
		num = Integer.parseInt(scanner.next());
		for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		}
		scanner.close();
    }
} Main public static void main(String[] a){
		int num1[] = new int[1000];
		int num2[] = new int[1000];
		int num3[] = new int[1000];
		int num,i = 0;
		Scanner scanner = new Scanner(System.in);
		num = Integer.parseInt(scanner.next());
		for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		}
		scanner.close();
    } main {
		int num1[] = new int[1000];
		int num2[] = new int[1000];
		int num3[] = new int[1000];
		int num,i = 0;
		Scanner scanner = new Scanner(System.in);
		num = Integer.parseInt(scanner.next());
		for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		}
		scanner.close();
    } int num1[] = new int[1000]; num1 new int[1000] 1000 int num2[] = new int[1000]; num2 new int[1000] 1000 int num3[] = new int[1000]; num3 new int[1000] 1000 int num num i = 0; i 0 Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) num = Integer.parseInt(scanner.next()) num Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		} i=0; i=0 i 0 i<num i num i++ i++ i {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		} {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		} num1[i] = Integer.parseInt(scanner.next()) num1[i] num1 i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner num2[i] = Integer.parseInt(scanner.next()) num2[i] num2 i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner num3[i] = Integer.parseInt(scanner.next()) num3[i] num3 i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} (Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2)) (Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2)) (Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2)) Math.pow(num1[i], 2) + Math.pow(num2[i], 2) Math.pow(num1[i], 2) Math.pow Math num1[i] num1 i 2 Math.pow(num2[i], 2) Math.pow Math num2[i] num2 i 2 Math.pow(num3[i], 2) Math.pow Math num3[i] num3 i 2 (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2)) Math.pow(num1[i], 2) + Math.pow(num3[i], 2) Math.pow(num1[i], 2) Math.pow Math num1[i] num1 i 2 Math.pow(num3[i], 2) Math.pow Math num3[i] num3 i 2 Math.pow(num2[i], 2) Math.pow Math num2[i] num2 i 2 (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2)) Math.pow(num2[i], 2) + Math.pow(num3[i], 2) Math.pow(num2[i], 2) Math.pow Math num2[i] num2 i 2 Math.pow(num3[i], 2) Math.pow Math num3[i] num3 i 2 Math.pow(num1[i], 2) Math.pow Math num1[i] num1 i 2 {
				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" scanner.close() scanner.close scanner String[] a a
import java.util.Scanner;
class Main{
    public static void main(String[] a){
		int num1[] = new int[1000];
		int num2[] = new int[1000];
		int num3[] = new int[1000];
		int num,i = 0;
		Scanner scanner = new Scanner(System.in);
		num = Integer.parseInt(scanner.next());
		for(i=0; i<num; i++) {
			num1[i] = Integer.parseInt(scanner.next());
			num2[i] = Integer.parseInt(scanner.next());
			num3[i] = Integer.parseInt(scanner.next());
			if((Math.pow(num1[i], 2) + Math.pow(num2[i], 2) == Math.pow(num3[i], 2))
					|| (Math.pow(num1[i], 2) + Math.pow(num3[i], 2) == Math.pow(num2[i], 2))
					|| (Math.pow(num2[i], 2) + Math.pow(num3[i], 2) == Math.pow(num1[i], 2))){
				System.out.println("YES");
			} else{
				System.out.println("NO");	
			} 
		}
		scanner.close();
    }
}
