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

int main()
{
        int a, b, c;
        int num;

        cin >> num;

        for(int i=0; i<num; i++){
                cin >> a >> b >> c;
                if( a>=b && a>=c ){
                        (a*a == b*b+c*c) ? cout<<"YES\n" : cout<<"NO\n";
                }else if( b>=a && b>=c ){
                        (b*b == a*a+c*c) ? cout<<"YES\n" : cout<<"NO\n";
                }else if( c>=a && c>=b ){
                        (c*c == b*b+a*a) ? cout<<"YES\n" : cout<<"NO\n";
                }
        }

        return 0;
}