import java.io.*;
 
public class Main {
    public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    }
 
    static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    }
} import java.io.*; io.* java public class Main {
    public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    }
 
    static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    }
} Main public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    } main {
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    } int n; n int sides[] = new int[3]; sides new int[3] 3 boolean judge = false; judge false String line; line String tmp[]; tmp BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); reader new BufferedReader(new InputStreamReader(System.in)) try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        } catch(IOException e){
            System.exit(0);
        } IOException e {
            System.exit(0);
        } System.exit(0) System.exit System 0 {
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        } line = reader.readLine() line reader.readLine() reader.readLine reader n = Integer.parseInt(line) n Integer.parseInt(line) Integer.parseInt Integer line for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            } {
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            } line = reader.readLine() line reader.readLine() reader.readLine reader tmp = line.split(" ") tmp line.split(" ") line.split line " " for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                } int j = 0; int j = 0; j 0 j < sides.length j sides.length sides sides.length j++ j++ j {
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                } {
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                } sides[j] = Integer.parseInt(tmp[j]) sides[j] sides j Integer.parseInt(tmp[j]) Integer.parseInt Integer tmp[j] tmp j sides[j] *= sides[j] sides[j] sides j sides[j] sides j for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                } int j = 0; int j = 0; j 0 j < sides.length j sides.length sides sides.length j++ j++ j {
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                } {
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                } if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false; sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3] sides[j%3] sides j%3 j 3 sides[(j+1)%3] + sides[(j+2)%3] sides[(j+1)%3] sides (j+1)%3 (j+1) j 1 3 sides[(j+2)%3] sides (j+2)%3 (j+2) j 2 3 {
                        judge = true;
                        break;
                    } judge = true judge true break; judge = false judge false Answer(judge) Answer judge String args[] args static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    } Answer {
        if(j) System.out.println("YES");
        else System.out.println("NO");
    } if(j) System.out.println("YES");
        else System.out.println("NO"); j 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" boolean j j public class Main {
    public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    }
 
    static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    }
} public class Main {
    public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    }
 
    static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    }
} Main
import java.io.*;
 
public class Main {
    public static void main(String args[]){
        int n;
        int sides[] = new int[3];
        boolean judge = false;
        String line;
        String tmp[];
        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
        try{
            line = reader.readLine();
            n = Integer.parseInt(line);
            for(int i = 0; i < n; i++){
                line = reader.readLine();
                tmp = line.split(" ");
                for(int j = 0; j < sides.length; j++){
                    sides[j] = Integer.parseInt(tmp[j]);
                    sides[j] *= sides[j];
                }
                for(int j = 0; j < sides.length; j++){
                    if(sides[j%3] == sides[(j+1)%3] + sides[(j+2)%3]) {
                        judge = true;
                        break;
                    }else
                        judge = false;
                }
                Answer(judge);
            }
        }catch(IOException e){
            System.exit(0);
        }
    }
 
    static void Answer(boolean j){
        if(j) System.out.println("YES");
        else System.out.println("NO");
    }
}