#include "bits/stdc++.h"
using namespace std;

int main() {
	int N, A[3];
	cin >> N;
	for (int i = 0; i < N; i++) {
		cin >> A[0] >> A[1] >> A[2];
		sort(A, A + 3);
		if (A[0] * A[0] + A[1] * A[1] == A[2] * A[2]) cout << "YES" << endl;
		else cout << "NO" << endl;
	}
}
