import sys;

for line in sys.stdin:
	n = int(line);
	for i in range(0, n):
		a = [int(num) for num in input().split()];
		a.sort();
		if a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2):
			print('YES');
		else:
			print('NO'); import sys sys for line in sys.stdin:
	n = int(line);
	for i in range(0, n):
		a = [int(num) for num in input().split()];
		a.sort();
		if a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2):
			print('YES');
		else:
			print('NO'); line sys.stdin sys stdin n = int(line) n int(line) int line for i in range(0, n):
		a = [int(num) for num in input().split()];
		a.sort();
		if a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2):
			print('YES');
		else:
			print('NO'); i range(0, n) range 0 n int(num) for num in input().split() for num in input().split() num input().split() ().split () input split for num in input().split() int(num) int num a = [int(num) for num in input().split()] a [int(num) for num in input().split()] a.sort() a.sort a sort if a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2):
			print('YES');
		else:
			print('NO'); a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2) a[2] ** 2 a[2] a 2 2 (a[0] ** 2) + (a[1] ** 2) a[0] ** 2 a[0] a 0 2 a[1] ** 2 a[1] a 1 2 print('YES') print 'YES' print('NO') print 'NO' a = [int(num) for num in input().split()] [int(num) for num in input().split()] a n = int(line) int(line) n
import sys;

for line in sys.stdin:
	n = int(line);
	for i in range(0, n):
		a = [int(num) for num in input().split()];
		a.sort();
		if a[2] ** 2 == (a[0] ** 2) + (a[1] ** 2):
			print('YES');
		else:
			print('NO');