#include <cstdio>
#include <algorithm>

using namespace std;

//input
int a[3];

void solve(){
	sort(a, a + 3);
	if(a[0] * a[0] + a[1] * a[1] == a[2] * a[2])
		printf("YES\n");
	else
		printf("NO\n");
}

int main(int argc, char const *argv[]){
//	freopen("in.txt", "r", stdin);

	int t;
	scanf("%d", &t);
	while(t --){
		for(int i = 0; i < 3; i ++)
			scanf("%d", &a[i]);
		solve();
	}

	return 0;
}