

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

public class Main{

	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				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.Arrays; Arrays java.util public class Main{

	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		}

	}

} Main public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		}

	} main {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		}

	} 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 for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		} int j = 0; int j = 0; j 0 j < N j N j++ j++ j {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		} {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		} String[] arr = br.readLine().split(" "); arr br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int[] lens = new int[3]; lens new int[3] 3 for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			} int i = 0; int i = 0; i 0 i < 3 i 3 i++ i++ i {
				lens[i] = Integer.parseInt(arr[i]);
			} {
				lens[i] = Integer.parseInt(arr[i]);
			} lens[i] = Integer.parseInt(arr[i]) lens[i] lens i Integer.parseInt(arr[i]) Integer.parseInt Integer arr[i] arr i Arrays.sort(lens) Arrays.sort Arrays lens if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			} lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1] lens[2] * lens[2] lens[2] lens 2 lens[2] lens 2 lens[0] * lens[0] + lens[1] * lens[1] lens[0] * lens[0] lens[0] lens 0 lens[0] lens 0 lens[1] * lens[1] lens[1] lens 1 lens[1] lens 1 {
				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 {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		}

	}

} public class Main{

	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				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.Arrays;

public class Main{

	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		
		int N = Integer.parseInt(br.readLine());
		
		for (int j = 0; j < N; j++) {
			String[] arr = br.readLine().split(" ");
			
			int[] lens = new int[3];
			for (int i = 0; i < 3; i++) {
				lens[i] = Integer.parseInt(arr[i]);
			}
			
			Arrays.sort(lens);
			
			if (lens[2] * lens[2] == lens[0] * lens[0] + lens[1] * lens[1]) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}			
		}

	}

}