num=int(input())
for i in range(num):
    list=[int(i) for i in input().split()]
    list.sort();
    if pow(list[0],2) + pow(list[1],2) == pow(list[2],2):
        print('YES')
    else:
        print('NO') num=int(input()) num int(input()) int input() input for i in range(num):
    list=[int(i) for i in input().split()]
    list.sort();
    if pow(list[0],2) + pow(list[1],2) == pow(list[2],2):
        print('YES')
    else:
        print('NO') i range(num) range num int(i) for i in input().split() for i in input().split() i input().split() ().split () input split for i in input().split() int(i) int i list=[int(i) for i in input().split()] list [int(i) for i in input().split()] list.sort() list.sort list sort if pow(list[0],2) + pow(list[1],2) == pow(list[2],2):
        print('YES')
    else:
        print('NO') pow(list[0],2) + pow(list[1],2) == pow(list[2],2) pow(list[0],2) + pow(list[1],2) pow(list[0],2) pow list[0] list 0 2 pow(list[1],2) pow list[1] list 1 2 pow(list[2],2) pow list[2] list 2 2 print('YES') print 'YES' print('NO') print 'NO' num=int(input()) int(input()) num list=[int(i) for i in input().split()] [int(i) for i in input().split()] list
num=int(input())
for i in range(num):
    list=[int(i) for i in input().split()]
    list.sort();
    if pow(list[0],2) + pow(list[1],2) == pow(list[2],2):
        print('YES')
    else:
        print('NO')