#include <iostream>
#include <string>
#include <algorithm>
#include <utility>
#include <stack>
#include <queue>
#include <vector>

#define pb push_back

using namespace std;

typedef long long ll;

int main()
{
        int n;
        cin >> n;
        vector<int> a(3);
        int max;
        while(n--){
                for(int i=0; i<3; ++i) cin >> a[i];
                max = *max_element(a.begin(), a.end());
                if(max*max == a[0]*a[0] + a[1]*a[1] + a[2]*a[2] - max*max) cout << "YES" << endl;
                else cout << "NO" << endl;
        }

        return 0;
}
