#include<stdio.h>
int main(void){
  int max,min,a,b,c,d,e,f,i,j;
int n[9999];
j=0;
scanf(" %d", &i);
while(j<i){
scanf(" %d %d %d",&a,&b,&c);

if(a>b){
  if(a>c){
    max=a;
  min=b*b+c*c;}
  else max=c;}
 else if(b>c)
   max=b;
     else max=c;
//printf("%d\n%d %d %d %d\n",max,a*a,b*b,c*c,max*max);
 if(a*a+b*b+c*c==2*max*max)
   n[j]=1;
 else n[j]=0;
 j++;}
for(j=0;j<i;j++){
  if(n[j])
    printf("YES\n");
  else 
    printf("NO\n");
 }
return 0;
}