#include<iostream>
using namespace std;
bool CheckT(int a,int b,int c);

int main(){
	int a,b,c,i,n;
	cin>>n;
	i=0;
	while(i<n){
		cin>>a>>b>>c;
		if(CheckT(a,b,c))cout<<"YES"<<endl;
		else cout<<"NO"<<endl;
		a=b=c=0;
		i++;

	}
	return 0;
}

bool CheckT(int a,int b,int c){
	a*=a;
	b*=b;
	c*=c;
	if(a+b==c||b+c==a||a+c==b)return true;
	else return false;
}