#include<iostream>
using namespace std;

int main(){
int n;
cin >> n;
int b;
int c;
int d;
int e;
int f;
int g;
int a;
a=0;
while(a<n){
cin >> b;
cin >> c;
cin >> d;
e=b*b;
f=c*c;
g=d*d;
if(e==f+g){cout <<"YES"<<endl;}
else if(f==e+g){cout <<"YES"<<endl;}
else if(g==f+e){cout <<"YES"<<endl;}
else{cout <<"NO"<<endl;}
a=a+1;}
    return 0;
}