#include <iostream>
#include <algorithm>
using namespace std;

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