import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    }

    private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    }
} import java.util.ArrayList; ArrayList java.util import java.util.Collections; Collections java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    }

    private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    }
} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    } main {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) List<Integer> list = new ArrayList<Integer>(); list new ArrayList<Integer>() int limit = Integer.parseInt(scanner.next()); limit Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        } int i = 0; int i = 0; i 0 i < limit i limit i++ i++ i {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        } {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        } for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            } int j = 0; int j = 0; j 0 j < 3 j 3 j++ j++ j {
                list.add(Integer.parseInt(scanner.next()));
            } {
                list.add(Integer.parseInt(scanner.next()));
            } list.add(Integer.parseInt(scanner.next())) list.add list Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner Collections.sort(list) Collections.sort Collections list Collections.reverse(list) Collections.reverse Collections list int a = list.get(0); a list.get(0) list.get list 0 int b = list.get(1); b list.get(1) list.get list 1 int c = list.get(2); c list.get(2) list.get list 2 double cosA = getCosA(a, b, c); cosA getCosA(a, b, c) getCosA a b c if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            } cosA == 0.0 cosA 0.0 {
                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" list.clear() list.clear list String[] args args private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    } getCosA {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    } return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c); (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c) (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) Math.pow(b, 2) + Math.pow(c, 2) Math.pow(b, 2) Math.pow Math b 2 Math.pow(c, 2) Math.pow Math c 2 Math.pow(a, 2) Math.pow Math a 2 (2 * b * c) 2 * b * c 2 b c int a a int b b int c c public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    }

    private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    }

    private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    }
} Main
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Integer> list = new ArrayList<Integer>();
        int limit = Integer.parseInt(scanner.next());
        for (int i = 0; i < limit; i++) {
            for (int j = 0; j < 3; j++) {
                list.add(Integer.parseInt(scanner.next()));
            }
            Collections.sort(list);
            Collections.reverse(list);
            int a = list.get(0);
            int b = list.get(1);
            int c = list.get(2);
            double cosA = getCosA(a, b, c);
            if (cosA == 0.0) {
                System.out.println("YES");
            } else {
                System.out.println("NO");
            }
            list.clear();
        }
    }

    private static double getCosA(int a, int b, int c) {
        return (Math.pow(b, 2) + Math.pow(c, 2) - Math.pow(a, 2)) / (2 * b * c);
    }
}