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

#define rep(p,q) for(int i = p; i < q;i++)

//3
int main(void) {
	int num;
	cin >> num;
	rep(0, num) {
		vector<int> line = vector<int>();
		rep(0, 3){
			int a;
			cin >> a;
			line.push_back(a);
		}
		sort(line.begin(),line.end());
		if (pow(line[0],2.0)  + pow(line[1],2.0) == pow(line[2],2.0)) cout << "YES" << endl;
		else cout << "NO" << endl;
	}
}

