import java.util.Arrays;
import java.util.Scanner;

public class Main {
	
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	}

} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
	
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	}

} Main static Scanner sc =  new java.util.Scanner(System.in); sc new java.util.Scanner(System.in) public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	} main {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	} int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		} int x = 0 ; int x = 0 ; x 0 x < n x n x++ x++ x {
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		} {
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		} int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc int [] array = new int [] {a,b,c}; array new int [] {a,b,c} Arrays.sort(array) Arrays.sort Arrays array int a2 = array[0]; a2 array[0] array 0 int b2 = array[1]; b2 array[1] array 1 int c2 = array[2]; c2 array[2] array 2 if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				} a2 * a2 + b2 * b2 == c2 * c2 a2 * a2 + b2 * b2 a2 * a2 a2 a2 b2 * b2 b2 b2 c2 * c2 c2 c2 {
				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 {
	
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	}

} public class Main {
	
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	}

} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		int n = sc.nextInt();
		
		for (int x = 0 ; x < n ; x++){
			
			int a = sc.nextInt();
			int b = sc.nextInt();
			int c = sc.nextInt();
			
			int [] array = new int [] {a,b,c};
			Arrays.sort(array);
			
			int a2 = array[0];
			int b2 = array[1];
			int c2 = array[2];
			
			if( a2 * a2 + b2 * b2 == c2 * c2 ){
				System.out.println( "YES" );
				}else{
					System.out.println( "NO" );
				}
			
		}
	}

}