import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;

public class Main {

    public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.Arrays; Arrays java.util import java.util.StringTokenizer; StringTokenizer java.util public class Main {

    public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    }
} Main public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    } main {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    } BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in)); reader new BufferedReader(new InputStreamReader(
                System.in)) StringBuilder builder = new StringBuilder(); builder new StringBuilder() StringTokenizer to; to int[] nums = new int[3]; nums new int[3] 3 int a = Integer.parseInt(reader.readLine()); a Integer.parseInt(reader.readLine()) Integer.parseInt Integer reader.readLine() reader.readLine reader for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        } int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        } {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        } to = new StringTokenizer(reader.readLine()) to new StringTokenizer(reader.readLine()) for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            } int j = 0; int j = 0; j 0 j < 3 j 3 j++ j++ j {
                nums[j] = Integer.parseInt(to.nextToken());
            } {
                nums[j] = Integer.parseInt(to.nextToken());
            } nums[j] = Integer.parseInt(to.nextToken()) nums[j] nums j Integer.parseInt(to.nextToken()) Integer.parseInt Integer to.nextToken() to.nextToken to Arrays.sort(nums) Arrays.sort Arrays nums if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n"); Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2) Math.pow(nums[0], 2) + Math.pow(nums[1], 2) Math.pow(nums[0], 2) Math.pow Math nums[0] nums 0 2 Math.pow(nums[1], 2) Math.pow Math nums[1] nums 1 2 Math.pow(
                    nums[2], 2) Math.pow Math nums[2] nums 2 2 builder.append("YES\n") builder.append builder "YES\n" builder.append("NO\n") builder.append builder "NO\n" System.out.print(builder) System.out.print System.out System System.out builder String[] args args public class Main {

    public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    }
} public class Main {

    public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;

public class Main {

    public static void main(String[] args) throws Exception {
        BufferedReader reader = new BufferedReader(new InputStreamReader(
                System.in));
        StringBuilder builder = new StringBuilder();
        StringTokenizer to;
        int[] nums = new int[3];
        int a = Integer.parseInt(reader.readLine());
        for (int i = 0; i < a; i++) {
            to = new StringTokenizer(reader.readLine());
            for (int j = 0; j < 3; j++) {
                nums[j] = Integer.parseInt(to.nextToken());
            }
            Arrays.sort(nums);
            if (Math.pow(nums[0], 2) + Math.pow(nums[1], 2) == Math.pow(
                    nums[2], 2))
                builder.append("YES\n");
            else
                builder.append("NO\n");
        }
        System.out.print(builder);

    }
}