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

int sq(int n){
    return n*n;
}

int main(){
    int n;
    cin >> n;
    while(n--){
        int arr[3];
        for(int i=0; i<3; i++){
            cin >> arr[i];
        }
        sort(arr,arr+3);
        if(sq(arr[0]) + sq(arr[1]) == sq(arr[2])){
            cout << "YES" << endl;
        } else
            cout << "NO" << endl;
    }
}