#include <iostream>
#include <algorithm>
using namespace std;
int main() {
    int n, e[3];
    cin >> n;
    for (int i=0; i<n; ++i) {
        cin >> e[0] >> e[1] >> e[2];
        sort(e, e+3);
        if (e[2] * e[2] == e[0] * e[0] + e[1] * e[1]) {
            cout << "YES" << endl;
        } else {
            cout << "NO" << endl;
        }
    }
    return 0;
}