#include<iostream>
#include<cmath>
using namespace std;
int main()

{
    int n;
    cin>>n;
    int a,b,c;
    for(int i=0;i<n;i++)
    {
        cin>>a>>b>>c;
        int d=a*a;
        int e=b*b;
        int f=c*c;
        if((d=e+f)||(e=d+f)||(f=d+e))cout<<"YES"<<endl;
        else cout<<"NO"<<endl;
    }
    return 0;
}
