#include <iostream>
#include <string>
#include <algorithm>
#include <cstdio>
#include <vector>
#include <queue>
#include <set>
#include <numeric>
#include <cmath>

using namespace std;

typedef long long int lld;

const lld mod = 1e9+7;
const lld INF = 1e9;
//const lld MAXN = 1e9;

int main()
{
	int n,a,b,c;

	cin >> n;
	for(int i = 0; i < n; i++)
	{
		cin >> a >> b >> c;

		int x,y,z;

		x = max(max(a,b),max(b,c));
		z = min(min(a,b),min(b,c));
		y = a+b+c-x-z;

		if (x*x == y*y + z*z)
		{
			cout << "YES" << endl;
		}else
		{
			cout << "NO" << endl;
		}
	}


	return 0;
}