function main(input) {
  var line = input.split("\n");
  
  line.slice(1, line.length).forEach(function(value) {
    var num = value.split(" ");
    num.sort(function(a, b) {return b - a;});
    console.log(num);

    var res = Math.pow(num[2], 2) + Math.pow(num[1], 2);
    if (res == Math.pow(num[0], 2)) {
      console.log("YES");
    } else {
      console.log("NO");
    }
  });
}

main(require("fs").readFileSync("/dev/stdin", "utf8"));