#include <iostream>
using namespace std;

int main(){
	int n;
	cin>>n;
	int a, b, c;
	while(cin>>a>>b>>c){
		int ansflg = false;
		if(a*a==b*b+c*c) ansflg = true;
		if(b*b==a*a+c*c) ansflg = true;
		if(c*c==b*b+a*a) ansflg = true;
		if(ansflg)
			cout<<"YES"<<endl;
		else
			cout<<"NO"<<endl;
	}
	return 0;
}