n = int(raw_input())
for i in range(n):
    e = map(int, raw_input().split())
    e.sort()
    if e[2] * e[2]== e[0] * e[0] + e[1] * e[1]:
        print "YES"
    else:
        print "NO" n = int(raw_input()) n int(raw_input()) int raw_input() raw_input for i in range(n):
    e = map(int, raw_input().split())
    e.sort()
    if e[2] * e[2]== e[0] * e[0] + e[1] * e[1]:
        print "YES"
    else:
        print "NO" i range(n) range n e = map(int, raw_input().split()) e map(int, raw_input().split()) map int raw_input().split() ().split () raw_input split e.sort() e.sort e sort if e[2] * e[2]== e[0] * e[0] + e[1] * e[1]:
        print "YES"
    else:
        print "NO" e[2] * e[2]== e[0] * e[0] + e[1] * e[1] e[2] * e[2] e[2] e 2 e[2] e 2 e[0] * e[0] + e[1] * e[1] e[0] * e[0] e[0] e 0 e[0] e 0 e[1] * e[1] e[1] e 1 e[1] e 1 print print e = map(int, raw_input().split()) map(int, raw_input().split()) e n = int(raw_input()) int(raw_input()) n
n = int(raw_input())
for i in range(n):
    e = map(int, raw_input().split())
    e.sort()
    if e[2] * e[2]== e[0] * e[0] + e[1] * e[1]:
        print "YES"
    else:
        print "NO"