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

public class Main {

	public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.*; util.* java public class Main {

	public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	}
} Main public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	} main {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	} BufferedReader r = new BufferedReader(new InputStreamReader(System.in)); r new BufferedReader(new InputStreamReader(System.in)) int n = Integer.parseInt(r.readLine()); n Integer.parseInt(r.readLine()) Integer.parseInt Integer r.readLine() r.readLine r StringTokenizer st; st int side[] = new int[3]; side new int[3] 3 for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		} {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		} st = new StringTokenizer(r.readLine()) st new StringTokenizer(r.readLine()) for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			} int j = 0; int j = 0; j 0 j < 3 j 3 j++ j++ j {
				 side[j] = Integer.parseInt(st.nextToken());
			} {
				 side[j] = Integer.parseInt(st.nextToken());
			} side[j] = Integer.parseInt(st.nextToken()) side[j] side j Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st Arrays.sort(side) Arrays.sort Arrays side if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            } (side[0]*side[0] + side[1]*side[1]) == side[2]*side[2] (side[0]*side[0] + side[1]*side[1]) side[0]*side[0] side[0] side 0 side[0] side 0 side[1]*side[1] side[1] side 1 side[1] side 1 side[2]*side[2] side[2] side 2 side[2] side 2 {
                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 {

	public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	}
} public class Main {

	public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	}
} Main

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

public class Main {

	public static void main(String[] args) throws IOException {
		
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(r.readLine());
		StringTokenizer st;
		
		int side[] = new int[3];
		
		for (int i = 0; i < n; i++) {
			st = new StringTokenizer(r.readLine());
			for(int j = 0;j < 3;j++){
				 side[j] = Integer.parseInt(st.nextToken());
			}
			Arrays.sort(side);
            if((side[0]*side[0] + side[1]*side[1]) == side[2]*side[2]) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
		}
		
	}
}