# coding: utf-8
num = int(input())
for i in range(num):
    ls = list([int(i) for i in input().split()])
    ls.sort()
    if ls[0]**2 + ls[1]**2 == ls[2]**2:
        print("YES")
    else:
        print("NO") num = int(input()) num int(input()) int input() input for i in range(num):
    ls = list([int(i) for i in input().split()])
    ls.sort()
    if ls[0]**2 + ls[1]**2 == ls[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 ls = list([int(i) for i in input().split()]) ls list([int(i) for i in input().split()]) list [int(i) for i in input().split()] ls.sort() ls.sort ls sort if ls[0]**2 + ls[1]**2 == ls[2]**2:
        print("YES")
    else:
        print("NO") ls[0]**2 + ls[1]**2 == ls[2]**2 ls[0]**2 + ls[1]**2 ls[0]**2 ls[0] ls 0 2 ls[1]**2 ls[1] ls 1 2 ls[2]**2 ls[2] ls 2 2 print("YES") print "YES" print("NO") print "NO" ls = list([int(i) for i in input().split()]) list([int(i) for i in input().split()]) ls num = int(input()) int(input()) num
# coding: utf-8
num = int(input())
for i in range(num):
    ls = list([int(i) for i in input().split()])
    ls.sort()
    if ls[0]**2 + ls[1]**2 == ls[2]**2:
        print("YES")
    else:
        print("NO")