(function Main() {
var input = require("fs").readFileSync("/dev/stdin", "utf8");
	input = input.split("\n");
  var n=parseInt(input[0],10);
  for(var i = 1; i <= n; i++){
    var tmp=input[i].split(" ");
	var a = parseInt(tmp[0], 10);
	var b = parseInt(tmp[1], 10);
    var c = parseInt(tmp[2], 10);
    if(a*a+b*b==c*c || a*a+c*c==b*b || a*a==b*b+c*c) console.log("YES");
    else console.log("NO");
  }
})();

