#include<cstdio>
#include<iostream>
#include<algorithm>
#define rep(i,n) for(int i=0;i<n;++i)
using namespace std;

int main() {
	int a[3];
	int n;
	cin >> n;
	while (n--) {
		rep(i, 3)cin >> a[i];
		sort(a, a + 3);
		if (a[0] * a[0] + a[1] * a[1] == a[2] * a[2]) {
			printf("YES\n");
		}
		else {
			printf("NO\n");
		}
	}
	return 0;
}