import std.stdio;
import std.conv;
import std.string;

const int DATA = 200;

int main() {
  int data = to!(int)(chomp(readln));
  string[] result = new string[data];

  for(int i=0; i<data; i++) {
    int a, b, c, tmp; // a:max
    string[] input = (chomp(readln)).split(" ");
    a = to!(int)(input[0]);
    b = to!(int)(input[1]);
    c = to!(int)(input[2]);
    if(a<b) {
      tmp = a;
      a = b;
      b = tmp;
    }
    if(a<c) {
      tmp = a;
      a = c;
      c = tmp;
    }
    if(a*a == b*b+c*c) result[i]="YES";
    else result[i]="NO";
  }

  for(int i=0; i<data; i++) writeln(result[i]);
  
  return 0;
}