import std.stdio;
import std.conv;
import std.algorithm;

int main(string[] args)
{
	int[] values;
	values.length = 3;

	int i;
	readf("%d",&i);

	for(int j=0;j<i;j++)
	{
		scanf("%d %d %d",&values[0] ,&values[1],&values[2]);
		sort(values);

		if(values[0]*values[0] + values[1]*values[1] == values[2]*values[2]){
			writeln("YES");
		}else{
			writeln("NO");
		}
	}
	return 0;
}