#include<iostream>
using namespace std;

int a, b, c;

int check(){
	if(a*a+b*b == c*c || a*a+c*c == b*b || b*b+c*c == a*a)
		return 1;
	return 0;
}

int main(){
	int t;
	cin >> t;
	for(int i = 0; i < t; i++){
		cin >> a >> b >> c;
		if(check())
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}
}
