import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] args) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	public static void main(String[] args) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
} Main public static void main(String[] args) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	} main {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	} BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); in new BufferedReader(new InputStreamReader(System.in)) try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} NumberFormatException e {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} e.printStackTrace() e.printStackTrace e catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} IOException e {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} e.printStackTrace() e.printStackTrace e {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} int lim = Integer.parseInt(in.readLine()); lim Integer.parseInt(in.readLine()) Integer.parseInt Integer in.readLine() in.readLine in for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			} int i = 0; int i = 0; i 0 i < lim i lim i++ i++ i {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			} {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			} String[] values = in.readLine().split(" "); values in.readLine().split(" ") in.readLine().split in.readLine() in.readLine in " " int a = Integer.parseInt(values[0]); a Integer.parseInt(values[0]) Integer.parseInt Integer values[0] values 0 int b = Integer.parseInt(values[1]); b Integer.parseInt(values[1]) Integer.parseInt Integer values[1] values 1 int c = Integer.parseInt(values[2]); c Integer.parseInt(values[2]) Integer.parseInt Integer values[2] values 2 int x = a * a; x a * a a a int y = b * b; y b * b b b int z = c * c; z c * c c c if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO"); ((x + y) == z) || ((y + z) == x) || ((z + x) == y) ((x + y) == z) || ((y + z) == x) || ((z + x) == y) ((x + y) == z) (x + y) x y z ((y + z) == x) (y + z) y z x ((z + x) == y) (z + x) z x y 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) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
} public class Main {
	public static void main(String[] args) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] args) {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
	    
		try {
			int lim = Integer.parseInt(in.readLine());
			
			for (int i = 0; i < lim; i++) {
				String[] values = in.readLine().split(" ");
				int a = Integer.parseInt(values[0]);
				int b = Integer.parseInt(values[1]);
				int c = Integer.parseInt(values[2]);

				int x = a * a;
				int y = b * b;
				int z = c * c;
				if (((x + y) == z) || ((y + z) == x) || ((z + x) == y)) System.out.println("YES");
				else System.out.println("NO");
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}