#include <iostream>
#include <cmath>
using namespace std;

int main()
{
    int m,n,k,j,i,sum=0;
    cin>>j;
       for(i=0;i<j;i++)
    {
    cin>>m>>n>>k;
    if(sqrt(m*m+n*n)==k)
    {
        cout<<"YES"<<endl;
    }
    else if(sqrt(m*m+k*k)==n)
        {
            cout<<"YES"<<endl;
        }
    else if(sqrt(k*k+n*n)==m)
    {
       cout<<"YES"<<endl;
    }
    else
cout<<"NO"<<endl;
    }

return 0;
}