function main(input) {
	var lines = input.split("\n");
	var problemCount = parseInt(lines.shift());
	lines = lines.slice(0, problemCount);
	for (var i = 0; i < lines.length; i++) {
		var sides = lines[i].split(" ").slice(0,3)
		.map(function(value) {
			return parseInt(value);
		})
		.sort(function (a, b) {
			return a - b;
		});
		if(!isNaN(sides[0] && !isNaN(sides[1]) && !isNaN(sides[2]))) {
			console.log((Math.pow(sides[2],2) === Math.pow(sides[1],2) + Math.pow(sides[0],2)) ?
				'YES' :
				'NO');
		}
	}
}
main(require('fs').readFileSync('/dev/stdin','utf8'));