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

public class Main {
    public static void main(String[] args) throws Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
    public static void main(String[] args) throws Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    }
} Main public static void main(String[] args) throws Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    } main {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    } StringBuffer sb = new StringBuffer(); sb new StringBuffer() 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 double a a b b c; c for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        } {
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        } String[] str = (br.readLine()).split(" "); str (br.readLine()).split(" ") (br.readLine()).split (br.readLine()) br.readLine br " " a = Math.pow(Integer.parseInt(str[0]),2) a Math.pow(Integer.parseInt(str[0]),2) Math.pow Math Integer.parseInt(str[0]) Integer.parseInt Integer str[0] str 0 2 b = Math.pow(Integer.parseInt(str[1]),2) b Math.pow(Integer.parseInt(str[1]),2) Math.pow Math Integer.parseInt(str[1]) Integer.parseInt Integer str[1] str 1 2 c = Math.pow(Integer.parseInt(str[2]),2) c Math.pow(Integer.parseInt(str[2]),2) Math.pow Math Integer.parseInt(str[2]) Integer.parseInt Integer str[2] str 2 2 if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            } a+b==c || a+c==b || b+c==a a+b==c || a+c==b || b+c==a a+b==c a+b a b c a+c==b a+c a c b b+c==a b+c b c a {
                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 Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
    public static void main(String[] args) throws Exception {
        StringBuffer sb = new StringBuffer();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        
        double a,b,c;
        for(int i=0;i<n;i++){
            String[] str = (br.readLine()).split(" ");
            a = Math.pow(Integer.parseInt(str[0]),2);
            b = Math.pow(Integer.parseInt(str[1]),2);
            c = Math.pow(Integer.parseInt(str[2]),2);
            if(a+b==c || a+c==b || b+c==a){
                sb.append("YES\n");
            }
            else{
                sb.append("NO\n");
            }
        }
        System.out.print(sb);
    }
}