#include<stdio.h>
#include<math.h>

int main(){
  int a, b, c, k;
  int i=0;
  scanf("%d", &k);
  while(i<k){
    scanf("%d %d %d", &a, &b, &c);
    i++;
    int max = (int)fmax((double)a, fmax((double)b, (double)c));
    int sum = a*a + b*b + c*c;
    if (sum==2*max*max)
      printf("YES\n");
    else
      printf("NO\n");
  }
  return 0;
}