# include<iostream>
using namespace std;

int main(){
    int N(0);
    cin >> N;
    
    int answer[N];
    int i(0);
    
    while(i < N){
        int a(0), b(0), c(0);
        cin >> a >> b >> c;
    
        answer[i] = 0;
        
        if (a > b && a > c){
            if(b*b + c*c == a*a) answer[i] = 1;
        }if (b > c && b > a){
            if(c*c + a*a == b*b) answer[i] = 1;
        }if (c > a && c > b){
            if(a*a + b*b == c*c) answer[i] = 1;
        }
        i++;
    }
    
    for(i=0; i<N;i++){
        if(answer[i] == 1) printf("YES\n");
        else printf("No\n");
    }
    return 0;
}

