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

public class Main {

	public static void main(String[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	}

	public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	}



} 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[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	}

	public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	}



} Main public static void main(String[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	} main {

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	} String strLine =""; strLine "" BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in)); stdReader new BufferedReader(new InputStreamReader(System.in)) int i = 0; i 0 int max = 1000; max 1000 String[] result = new String [max]; result new String [max] max while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		} i <= max && ((strLine = stdReader.readLine()) != null) i <= max i max ((strLine = stdReader.readLine()) != null) (strLine = stdReader.readLine()) strLine stdReader.readLine() stdReader.readLine stdReader null {

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		} if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				} i == 0 i 0 {
				max = Integer.parseInt(strLine);

			} max = Integer.parseInt(strLine) max Integer.parseInt(strLine) Integer.parseInt Integer strLine {
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				} String[] temp = strLine.split(" ",0); temp strLine.split(" ",0) strLine.split strLine " " 0 int[] tempInt = new int[3]; tempInt new int[3] 3 tempInt[0] = Integer.parseInt(temp[0]) tempInt[0] tempInt 0 Integer.parseInt(temp[0]) Integer.parseInt Integer temp[0] temp 0 tempInt[1] = Integer.parseInt(temp[1]) tempInt[1] tempInt 1 Integer.parseInt(temp[1]) Integer.parseInt Integer temp[1] temp 1 tempInt[2] = Integer.parseInt(temp[2]) tempInt[2] tempInt 2 Integer.parseInt(temp[2]) Integer.parseInt Integer temp[2] temp 2 result[i-1]=calc(tempInt) result[i-1] result i-1 i 1 calc(tempInt) calc tempInt i++ i if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		} i > 1 i 1 {
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		} for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			} int j = 0; int j = 0; j 0 j < max j max j++ j++ j {
				System.out.println(result[j]);
			} {
				System.out.println(result[j]);
			} System.out.println(result[j]) System.out.println System.out System System.out result[j] result j String[] a a public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	} calc {

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	} java.util.Arrays.sort(tempInt) java.util.Arrays.sort java.util.Arrays java.util java java.util java.util.Arrays tempInt if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		} (tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2]) (tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1]) (tempInt[0]*tempInt[0]) tempInt[0] tempInt 0 tempInt[0] tempInt 0 (tempInt[1]*tempInt[1]) tempInt[1] tempInt 1 tempInt[1] tempInt 1 (tempInt[2]*tempInt[2]) tempInt[2] tempInt 2 tempInt[2] tempInt 2 {

			return "YES";
		} return "YES"; "YES" {
			return "NO";
		} return "NO"; "NO" int[] tempInt tempInt public class Main {

	public static void main(String[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	}

	public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	}



} public class Main {

	public static void main(String[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	}

	public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	}



} Main

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

public class Main {

	public static void main(String[] a) throws IOException{

		String strLine ="";
		BufferedReader stdReader =
				new BufferedReader(new InputStreamReader(System.in));

		int i = 0;
		int max = 1000;
		String[] result = new String [max];

		while ( i <= max && ((strLine = stdReader.readLine()) != null) ){

			if(i == 0){
				max = Integer.parseInt(strLine);

			}else{
				//??????????????§?????????
				String[] temp = strLine.split(" ",0);
				int[] tempInt = new int[3];
				tempInt[0] = Integer.parseInt(temp[0]);
				tempInt[1] = Integer.parseInt(temp[1]);
				tempInt[2] = Integer.parseInt(temp[2]);


				//????§???¢???????????????????????????????????????result???????´?
				result[i-1]=calc(tempInt);
				}

			i++;

		}


		//?????????????????????
		if(i > 1){
			for(int j = 0; j < max; j++){
				System.out.println(result[j]);
			}
		}

	}

	public static String calc(int[] tempInt){

		java.util.Arrays.sort(tempInt);

		if((tempInt[0]*tempInt[0])+(tempInt[1]*tempInt[1])==(tempInt[2]*tempInt[2])){

			return "YES";
		}else{
			return "NO";
		}


	}



}