#include<iostream>
#include<algorithm>
#include<math.h>

using namespace std;

int compare(const void *a, const void *b)
{
    return *(int*)a - *(int*)b;
}

int main(){
    int n;
    cin >> n;
    for (int i = 0; i < n; i++){
        int arr[3];
        cin >> arr[0] >> arr[1] >> arr[2];
        sort(arr, arr + 3);

        if (pow(arr[0], 2) + pow(arr[1], 2) == pow(arr[2], 2))
        {
            cout << "YES" << endl;
        }
        else
        {
            cout << "NO" << endl;
        }

    }


    return 0;
}