import java.util.*;

public class Main {

	public static void main(String[] args) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	}
	}
		 import java.util.*; util.* java public class Main {

	public static void main(String[] args) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	}
	} Main public static void main(String[] args) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	} main {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	} int x=0 x 0 y=0 y 0 a=0 a 0 b=0 b 0 c=0; c 0 Scanner sc=new Scanner(System.in); sc new Scanner(System.in) x=sc.nextInt() x sc.nextInt() sc.nextInt sc for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		} int i=0; int i=0; i 0 i<x i x i++ i++ i {
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		} {
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		} a=sc.nextInt() a sc.nextInt() sc.nextInt sc b=sc.nextInt() b sc.nextInt() sc.nextInt sc c=sc.nextInt() c sc.nextInt() sc.nextInt sc if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			} a>=b && a>=c a>=b a b a>=c a c if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			} b>=c b c {
				y=c;
				c=a;
				a=b;
				b=y;
			} y=c y c c=a c a a=b a b b=y b y if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			} c>=b c b {
				y=b;
				b=a;
				a=c;
				c=y;
			} y=b y b b=a b a a=c a c c=y c y if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO"); a*a==b*b+c*c a*a a a b*b+c*c b*b b b c*c c c 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) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	}
	} public class Main {

	public static void main(String[] args) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	}
	} Main
import java.util.*;

public class Main {

	public static void main(String[] args) {
	
		int x=0,y=0,a=0,b=0,c=0;
		Scanner sc=new Scanner(System.in);
		x=sc.nextInt();
		for(int i=0;i<x;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			c=sc.nextInt();
			if(a>=b && a>=c);
			else if(b>=c){
				y=c;
				c=a;
				a=b;
				b=y;
			}
			else if(c>=b){
				y=b;
				b=a;
				a=c;
				c=y;
			}
			if(a*a==b*b+c*c)System.out.println("YES");
			else System.out.println("NO");
		}
	
	}
	}
		