#include <stdio.h>
#include <algorithm>
#include <vector>
using namespace std;
vector<int>v;
int main(void)
{
    int testCase,n;
    scanf("%d",&testCase);
    while(testCase--){
        v.clear();
        int i=3;
        while(i--){
            scanf("%d",&n);
            v.push_back(n);
        }
        sort(v.begin(),v.end());
        if((v[0]*v[0]+v[1]*v[1])==(v[2]*v[2]))printf("YES\n");
        else printf("NO\n");
    }
    return 0;
}