#include<iostream>


using namespace std;

int main(void)
{
int n,a = 0,b = 0,c = 0;
cin>>n;

for(int i=0;i<n;i++)
{
    cin>>a>>b>>c;

        if(c*c == (b*b+a*a)|| (a * a + c * c )== b * b ||( b * b + c * c) == a * a){
        cout<<"YES"<<endl;
        }
        else{
            cout<<"NO"<<endl;
        }

}

return 0;
}