# AOJ 0003 Is it a Right Triangle?
# Python3 2018.6.7 bal4u

n = int(input())
for i in range(n):
    a = list(map(int, input().split()))
    a.sort()
    if a[0]*a[0] + a[1]*a[1] == a[2]*a[2]:
        print('YES')
    else:
        print('NO') n = int(input()) n int(input()) int input() input for i in range(n):
    a = list(map(int, input().split()))
    a.sort()
    if a[0]*a[0] + a[1]*a[1] == a[2]*a[2]:
        print('YES')
    else:
        print('NO') i range(n) range n a = list(map(int, input().split())) a list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split a.sort() a.sort a sort if a[0]*a[0] + a[1]*a[1] == a[2]*a[2]:
        print('YES')
    else:
        print('NO') a[0]*a[0] + a[1]*a[1] == a[2]*a[2] a[0]*a[0] + a[1]*a[1] a[0]*a[0] a[0] a 0 a[0] a 0 a[1]*a[1] a[1] a 1 a[1] a 1 a[2]*a[2] a[2] a 2 a[2] a 2 print('YES') print 'YES' print('NO') print 'NO' n = int(input()) int(input()) n a = list(map(int, input().split())) list(map(int, input().split())) a
# AOJ 0003 Is it a Right Triangle?
# Python3 2018.6.7 bal4u

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