
#include<iostream>
using namespace std;

int main(){
	int n;
	cin>>n;
	int i;
	for ( i = 0; i < n; i++ ){
	int a;
	int b;
	int c;
	cin>>a>>b>>c;
	int aa=a*a;
	int bb=b*b;
	int cc=c*c;
	if(aa==bb+cc){
	cout<<"YES"<<endl;}else
	if(bb==aa+cc){
	cout<<"YES"<<endl;}else
    if(cc==bb+aa){
	cout<<"YES"<<endl;}else
	{cout<<"NO"<<endl;}}
    return 0;
}
