#include <iostream>
#include <algorithm>
#include <vector>
using namespace std;

int main()
{
	int i,b,c,d;
	vector< int > a;

	cin >> i;
	for(int j=0; j<i; j++){
		cin >> b >> c >> d;
		a.push_back( b );
		a.push_back( c );
		a.push_back( d );
		sort(a.begin(), a.end());
		if(a[0]*a[0] + a[1]*a[1] == a[2]*a[2]){
			cout << "YES" << endl;
		}else{
			cout << "NO" << endl;
		}
		a.clear();
	}
}