#include <iostream>
#include <algorithm>
#include <cstdlib>
#include <queue>
using namespace std;

int main() {
	int iCase = 0;
	int a,b,c = 0;
	cin >> iCase;
	priority_queue<int,vector<int>,less<int> > que;

	while(iCase-- > 0 && cin >> a >> b >> c) {
		    
		que.push(a);
		que.push(b);
		que.push(c);

		int s1 = que.top(); que.pop();
		int s2 = que.top(); que.pop();
		int s3 = que.top(); que.pop();

		if (s3*s3 + s2*s2 == s1*s1)
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}

	return 0;
}