#include <iostream>
using namespace std;

int main() {
	// your code goes here
	int n;
	cin >> n;
	for (int i=0;i<n;i++) {
		int a,b,c;
		cin >> a >> b >>c;
		int aa = a*a;
		int bb = b*b;
		int cc = c*c;
		if (aa==bb+cc||bb==aa+cc||cc==aa+bb) {
			cout <<"YES"<<endl;
		}
		else {
			cout <<"NO"<<endl;
		}
	}
	return 0;
}