import java.util.Scanner;
public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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 {
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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) for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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");
		} int i = sc.nextInt(); int i = sc.nextInt(); i sc.nextInt() sc.nextInt sc i>0 i 0 i-- i-- i {
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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");
		} {
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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");
		} 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 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 System.out System System.out "YES" 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){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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){
		Scanner sc = new Scanner(System.in);
		for(int i = sc.nextInt(); i>0; i--){
			int a = sc.nextInt();
			int b = sc.nextInt();
			int 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");
		}
	}
}