import java.util.Scanner;

public class Main{
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	}
} import java.util.Scanner; Scanner java.util public class Main{
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	}
} Main public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	} main {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	} Scanner stdIn = new Scanner(System.in); stdIn new Scanner(System.in) int a; a int b; b int c; c int N = stdIn.nextInt(); N stdIn.nextInt() stdIn.nextInt stdIn int count = 0; count 0 int box; box while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		} true {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		} if(N<=0){
			break;
			} N<=0 N 0 {
			break;
			} break; a = stdIn.nextInt() a stdIn.nextInt() stdIn.nextInt stdIn b = stdIn.nextInt() b stdIn.nextInt() stdIn.nextInt stdIn c = stdIn.nextInt() c stdIn.nextInt() stdIn.nextInt stdIn if (a < b) {
				box = a;
				a = b;
				b = box;
			} a < b a b {
				box = a;
				a = b;
				b = box;
			} box = a box a a = b a b b = box b box if (a < c) {
				box = a;
				a = c;
				c = box;
			} a < c a c {
				box = a;
				a = c;
				c = box;
			} box = a box a a = c a c c = box c box a = a * a a a * a a a b = b * b b b * b b b c = c * c c c * c c c if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO"); a == b + c a b + c b c 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" count=count+1 count count+1 count 1 if (count == N){
				break;
			} count == N count N {
				break;
			} break; String[] args args public class Main{
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	}
} public class Main{
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	}
} Main
import java.util.Scanner;

public class Main{
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		int a;
		int b;
		int c;
		int N = stdIn.nextInt();
		int count = 0;
		int box;
		while (true) {
			if(N<=0){
			break;
			}
			a = stdIn.nextInt();
			b = stdIn.nextInt();
			c = stdIn.nextInt();
			if (a < b) {
				box = a;
				a = b;
				b = box;
			}
			if (a < c) {
				box = a;
				a = c;
				c = box;
			}
			a = a * a;
			b = b * b;
			c = c * c;
			if (a == b + c)
				System.out.println("YES");
			else
				System.out.println("NO");
			count=count+1;
			if (count == N){
				break;
			}
		}
	}
}