#include <iostream>
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <algorithm>
#include <stdlib.h>

using namespace std;


int main(){
	int N;
	cin >> N;

	int a[3];
	int i,j;

	for(j=0 ; j<N ; j++){

		for(i=0 ; i<3 ; i++){
			cin >> a[i];
		}

		sort(a, a+3);

		if(a[2]*a[2] == (a[0]*a[0] + a[1]*a[1])){
			cout << "YES" << endl;
		}else{
			cout << "NO" << endl;
		}

	}
	return 0;
}