#include <iostream>
#include <stdio.h>
#include <vector>
#include <algorithm>
#include <math.h>
#include <utility>

using namespace std;

#define FOR(i,k,n) for(int i = (k); i < (n); i++)
#define REP(i,n) FOR(i,0,n)

int main()
{
	int a[4],n;
	cin >> n;
	REP(i, n)
	{
		cin >> a[0] >> a[1] >> a[2];
		sort(a, a + 3);
		if (a[2] >= a[0] + a[1]) cout << "NO" << endl;
		else if (a[2] * a[2] == a[0] * a[0] + a[1] * a[1])cout << "YES" << endl;
		else cout << "NO" << endl;
	}
	return 0;
}