#include <iostream>
#include <math.h>
#include <string>
#include <algorithm>
#include <vector>
#define REP(i,n) for(int i=0;i<n;i++)
typedef long long ll;

using namespace std;
int kaijo(int n){
	int ans = 1;
	if (n != 0){
		for (int i = 0; i < n; i++){
			ans *= (n - i);
		}
	}
	else{
		ans = 1;
	}
	return ans;
}

int main(){
	int n;
	int tri[3];
	cin >> n;
	REP(i, n){
		cin >> tri[0] >> tri[1] >> tri[2];
		sort(tri, tri + 3);
		if (pow(tri[2], 2) == pow(tri[0], 2) + pow(tri[1], 2)){
			cout << "YES" << endl;
		}
		else{
			cout << "NO" << endl;
		}
	}
	return 0;
}