#include<iostream>

int a,b,c,n;

int main(){
	std::cin >> n;
	for(int i=0; i<n; i++){
		std::cin >> a >> b >> c;
		if((a*a + b*b == c*c)||(a*a + c*c == b*b)||(b*b + c*c == a*a))
			std::cout << "YES\n";
		else
			std::cout << "NO\n";
	}
	return 0;
}