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

public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	}

} 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) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	}

} Main public static void main(String[] args) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	} main {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int n = Integer.parseInt(br.readLine()); n Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br StringBuilder sb = new StringBuilder(); sb new StringBuilder() String[] s; s int a a b b c; c for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		} int i = 0; int i = 0; i 0 i < n i n ++i ++i i {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		} {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		} s = br.readLine().split(" ") s br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " a = Integer.parseInt(s[0]) a Integer.parseInt(s[0]) Integer.parseInt Integer s[0] s 0 b = Integer.parseInt(s[1]) b Integer.parseInt(s[1]) Integer.parseInt Integer s[1] s 1 c = Integer.parseInt(s[2]) c Integer.parseInt(s[2]) Integer.parseInt Integer s[2] s 2 if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			} a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b a*a == b*b + c*c || b*b == c*c + a*a || 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 == c*c + a*a b*b b b c*c + a*a c*c c c a*a a a c*c == a*a + b*b c*c c c a*a + b*b a*a a a b*b b b {
				sb.append("YES\n");
			} sb.append("YES\n") sb.append sb "YES\n" {
				sb.append("NO\n");
			} sb.append("NO\n") sb.append sb "NO\n" System.out.print(sb) System.out.print System.out System System.out sb String[] args args public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	}

} public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	}

} Main
import java.io.BufferedReader;
//import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws NumberFormatException, IOException {
		//System.setIn(new FileInputStream("./input.txt"));
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		
		StringBuilder sb = new StringBuilder();
		String[] s;
		int a, b, c;
		for(int i = 0; i < n; ++i) {
			s = br.readLine().split(" ");
			a = Integer.parseInt(s[0]);
			b = Integer.parseInt(s[1]);
			c = Integer.parseInt(s[2]);
			if(a*a == b*b + c*c || b*b == c*c + a*a || c*c == a*a + b*b) {
				sb.append("YES\n");
			}else{
				sb.append("NO\n");
			}
		}
		System.out.print(sb);
	}

}