#include<bits/stdc++.h>
using namespace std;
#define FOR(i,a,b) for (int i=(a);i<(b);i++)
#define RFOR(i,a,b) for (int i=(b)-1;i>=(a);i--)
#define REP(i,n) for (int i=0;i<(n);i++)
#define RREP(i,n) for (int i=(n)-1;i>=0;i--)
typedef long long LL;
int main(){
        LL N;
        cin>>N;
        REP(i,N){
            vector<int>v;
            int a,b,c;
            cin>>a>>b>>c;
            v.push_back(a);
            v.push_back(b);
            v.push_back(c);
            sort(v.begin(),v.end());
            if(v[0]*v[0]+v[1]*v[1]==v[2]*v[2]){
               cout<<"YES"<<endl;
            }else{
               cout<<"NO"<<endl;
            }
        }
	return(0);
}