#include <algorithm>
#include <iostream>
using namespace std;

int main(){
    int n;
    scanf("%d", &n);
    int sides[3];
    for (int i = 0; i < n; i++){
	cin >> sides[0] >> sides[1] >> sides[2];
	sort(sides, sides+3);
	printf("%s\n", (sides[0]*sides[0] + sides[1]*sides[1] == sides[2]*sides[2] && sides[2] < sides[1] + sides[2])? "YES" : "NO");
    }
}