import sys
r = []
n = int(input())
l = sys.stdin.readlines()
for i in l:
  x, y, z = sorted(map(lambda x:x*x,map(int, i.split())))
  if x + y == z:
      print("YES")
  else:
      print("NO") import sys sys r = [] r [] n = int(input()) n int(input()) int input() input l = sys.stdin.readlines() l sys.stdin.readlines() sys.stdin.readlines sys.stdin sys stdin readlines for i in l:
  x, y, z = sorted(map(lambda x:x*x,map(int, i.split())))
  if x + y == z:
      print("YES")
  else:
      print("NO") i l x, y, z = sorted(map(lambda x:x*x,map(int, i.split()))) x sorted(map(lambda x:x*x,map(int, i.split()))) sorted map(lambda x:x*x,map(int, i.split())) map lambda x:x*x x*x x x x map(int, i.split()) map int i.split() i.split i split y z if x + y == z:
      print("YES")
  else:
      print("NO") x + y == z x + y x y z print("YES") print "YES" print("NO") print "NO" y, z = sorted(map(lambda x:x*x,map(int, i.split()))) sorted(map(lambda x:x*x,map(int, i.split()))) y x, y, z = sorted(map(lambda x:x*x,map(int, i.split()))) sorted(map(lambda x:x*x,map(int, i.split()))) x r = [] [] r n = int(input()) int(input()) n l = sys.stdin.readlines() sys.stdin.readlines() l z = sorted(map(lambda x:x*x,map(int, i.split()))) sorted(map(lambda x:x*x,map(int, i.split()))) z
import sys
r = []
n = int(input())
l = sys.stdin.readlines()
for i in l:
  x, y, z = sorted(map(lambda x:x*x,map(int, i.split())))
  if x + y == z:
      print("YES")
  else:
      print("NO")