import java.util.Scanner;
public class Main {
    public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    }
    static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    }
    static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    }
} Main public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    } main {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    } Scanner scan = new Scanner (System.in); scan new Scanner (System.in) int n = Integer.parseInt(scan.nextLine()); n Integer.parseInt(scan.nextLine()) Integer.parseInt Integer scan.nextLine() scan.nextLine scan String[] input; input int a a b b c; c for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	} {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	} input = scan.nextLine().split(" ") input scan.nextLine().split(" ") scan.nextLine().split scan.nextLine() scan.nextLine scan " " a = Integer.parseInt(input[0]) a Integer.parseInt(input[0]) Integer.parseInt Integer input[0] input 0 b = Integer.parseInt(input[1]) b Integer.parseInt(input[1]) Integer.parseInt Integer input[1] input 1 c = Integer.parseInt(input[2]) c Integer.parseInt(input[2]) Integer.parseInt Integer input[2] input 2 if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    } isRightTriangle(a, b, c) isRightTriangle a b c {
		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" String[] args args static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    } isRightTriangle {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    } int a2 = a * a a2 a * a a a b2 = b * b b2 b * b b b c2 = c * c; c2 c * c c c if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	} a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2 a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2 a2 + b2 == c2 a2 + b2 a2 b2 c2 a2 + c2 == b2 a2 + c2 a2 c2 b2 b2 + c2 == a2 b2 + c2 b2 c2 a2 {
	    return true;
	} return true; true return false; false int a a int b b int c c public class Main {
    public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    }
    static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    }
} public class Main {
    public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    }
    static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    }
} Main
import java.util.Scanner;
public class Main {
    public static void main (String[] args) {
	Scanner scan = new Scanner (System.in);
	int n = Integer.parseInt(scan.nextLine());
	String[] input;
	int a, b, c;
	for (int i = 0; i < n; i++) {
	    input = scan.nextLine().split(" ");
	    a = Integer.parseInt(input[0]);
	    b = Integer.parseInt(input[1]);
	    c = Integer.parseInt(input[2]);
	    if (isRightTriangle(a, b, c)) {
		System.out.println("YES");
	    } else {
		System.out.println("NO");
	    }
	}
    }
    static boolean isRightTriangle (int a, int b, int c) {
	int a2 = a * a, b2 = b * b, c2 = c * c;
	if (a2 + b2 == c2 || a2 + c2 == b2 || b2 + c2 == a2) {
	    return true;
	}
	return false;
    }
}