Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)
var out = bufio.NewWriter(os.Stdout)

func main() {
	sc.Split(bufio.ScanWords)
	defer out.Flush()
	n := nextInt()
	for i := 0; i < n; i++ {
		data := nextInts(3)
		fmt.Fprintln(out, checkTriangle(data))
	}
}

func next() string {
	sc.Scan()
	return sc.Text()
}

func nextInt() int {
	a, _ := strconv.Atoi(next())
	return a
}

func nextInts(n int) []int {
	a := make([]int, n)
	for i := 0; i < n; i++ {
		a[i] = nextInt()
	}
	return a
}

func checkTriangle(i []int) string {
	if checkSt(i[0], i[1], i[2]) || checkSt(i[1], i[2], i[0]) || checkSt(i[2], i[0], i[1]) {
		return "YES"
	}
	return "NO"
}
func Sq(x int) int {
	return x * x
}

func checkSt(a, b, c int) bool {
	return (Sq(a) + Sq(b)) == Sq(c)
}

Python: import sys

for line in sys.stdin:
    try:
        a,b,c = [int(x) for x in line.split()]
        if (a**2+b**2) == c**2:
            print('YES')
        elif (a**2+c**2) == b**2:
            print('YES')
        elif (b**2+c**2) == a**2:
            print('YES')
        else:
            print('NO')
    except(ValueError):
        continue

Python: N = int(input())
for i in range(N):
    a, b, c = map(int, input().split(" "))
    if a * a + b * b == c * c or b * b + c * c == a * a or c * c + a * a == b * b:
        print("YES")
    else:
        print("NO")

Python: n = int(input())

for c in range(n):
    line = input()
    datas = map(int, line.split())
    li = list(datas) 
    a = li[0]
    b = li[1]
    c = li[2]

    if a < c and b < c:
        a2 = a ** 2
        b2 = b ** 2
        c2 = c ** 2
        if (a2 + b2) == c2:
            print("YES")
        else:
            print("NO")
    else:
        print("NO")

Python: N = int(input())
ans = []

for i in range(N) :
    a, b, c = sorted(list(map(int, input().split())))
    if a ** 2 + b ** 2 == c ** 2 :
        ans.append("YES")
    else :
        ans.append("NO")
        
for a in ans :
    print(a)

Python: # coding: utf-8
# Your code here!

N = int(input())

for i in range(N):
    a,b,c = map(int,input().split())
    a = a*a
    b = b*b
    c = c*c
    if a==b+c or b==a+c or c==a+b:
        print('YES')
    else:
        print('NO')

Python: N = int(input())
i=0
while i < N:
 x,y,z = map(int,input().split())
 if x<=z and y<=z: 
     if z**2 == x**2+y**2: print("YES")
     else: print("NO")
 elif x<=y and z<=y:
     if y**2 == x**2+z**2: print("YES")
     else: print("NO")
 else: 
     if x**2 == y**2+z**2: print("YES")
     else: print("NO")

 i += 1

Python: def main():
    n = int(input())
    n.sort()
    if n[0]**2+n[1]**2 != n[2]**2:
        print("NO")
    else:
        print("YES")

main()

Python: n=int(input())
for i in range(n):
	x=list(map(int,input().split()))
	a,b,c=sorted(x)
	if a**2+b**2==c**2:
		print('YES')
	else:
		print('NO')

Python: n=int(input())
for i in range(n):
 x=[int(j) for j in input().split()]
 x.sort()
 if x[2]**2==x[0]**2+x[1]**2:
  print("YES")
 else:
  print("NO")

Python: #1???????????????
num_data = int(input())


for i in range(num_data):
    input_line = input().split(" ")
    
    a = int(input_line[0])
    b = int(input_line[1])
    c = int(input_line[2])
    
    #?????????????????????????????????????????§
    if (pow(a,2) + pow(b,2) == pow(c,2) ) or (pow(a,2) + pow(c,2) == pow(b,2) ) or (pow(b,2) + pow(c,2) == pow(a,2)):  
        print("YES")
    else:
        print("NO")

Python: n = int(input())
for i in range(0, n):
    a, b, c = sorted(map(int, input().split()))
    print("YES" if c*c == a*a+b*b else "NO")

Python: n = int(input())
for i in range(n):
    nums = sorted(map(int, input().split()))
    print("YES" if nums[2]**2 == nums[1]**2 + nums[0]**2 else "NO")

Python: n = int(input())
L = [input() for i in range(n)]  #L????????????????´???¨???????????????
for line in L:
	A = line.split()  #A???line??????3????????°???????????????(?????????)
	B = sorted([int(A[i]) for i in range(3)])  #B???A?????°?????????????????????????????????
	if B[2]^2 == B[0]^2 + B[1]^2:
		print('YES')
	else:
		print('NO')

Python: x=int(input())

for _ in range(x):
    a,b,c=map(int,input().split())
    if a**2 + b**2 == c**2:
        print('YES')
    elif b**2 + c**2 == a**2:
        print('YES')
    elif c**2 + a**2 == b**2:
        print('YES')
    else:
        print('NO')

Python: import math

num = int(input())

for i in range(num):
    try:
        sides = list(map(int, input().split(" ")))
        sides.sort()

        if int(math.pow(sides[0], 2)) + int(math.pow(sides[1], 2)) == int(math.pow(sides[2], 2)):
            print("YES")
        else:
            print("NO")

    except:
        break

Python: cnt = int(input())
values = []
for i in range(cnt):
    values.append([int(x) for x in input().split()])

for x, y, z in values:
    if z ** 2 == x ** 2 + y ** 2:
        print('YES')
    else:
        print('NO')

Python: N=int(input())
i=0
while i<N:
    a,b,c=map(int,input().split())
    if a*a==b*b+c*c or b*b==c*c+a*a or c*c==a*a+b*b:
        print('YES')
    else:
        print('NO')
    i+=1

Python: n=int(input())#ｎはデータセットの数
for i in range(n):#ｎ回繰り返す
  edge=input().split()#入力
  edge=[int(j) for j in edge]#入力
  edge.sort()#ここでedge[2]が最大になる
  if(edge[0]**2+edge[1]**2==edge[2]**2):#直角三角形かどうか
    print("YES")
  else:#そうでないなら
    print("NO")

Python: n = int(input())

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

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

Python: def ifTriangle(a, b, c):
    if (a**2) + (b**2) == c**2: print("YES")
    else: print("NO")

n=int(input())
for i in range(n):
    lines=list(map(int, input().split()))
    lines.sort()
    ifTriangle(lines[0], lines[1], lines[2])

Python: input()
while True:
  try:
    lst = list(map(int,input().split()))
    lst.sort()
    if lst[2] ** 2 == lst[1] ** 2 + lst[0] ** 2:
      print("YES")
    else:
      print("NO")
  except EOFError:
    break

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

Python: n = int(input())
for _ in range(n):
	num = sorted(map(int, input().split()))
	print("YES" if num[2]**2 == num[1]**2 + num[0]**2 else "NO")

Python: deta_set_count = int(input())
for _ in range(deta_set_count):
    k = list(map(int, input().split()))
    k= k.sorted()
    if k[0]**2 + k[1]**2 == k[2]**2:
        print('YES')
    else:
        print('NO')

Python: for i in range(int(input())):
    a, b, c = sorted([int(x) for x in input().split()])
    print('YES' if (a**2 + b**2 == c**2) else 'NO')

Python: N=int(input())
l=[list(map(int,input().split())) for i in range(N)]

for i in l:
  i.sort()
  if (i[-1])**2 == (i[-2])**2 + (i[-3])**2:
    print("YES")
  else:print("NO")

Python: def main():
    n = int(input())
    for i in range(n):
        Array = list(map(int,input().split()))
        Array.sort()
        if Array[2]**2 == Array[0]**2 + Array[1]**2:
            print("yes")
        else:
            print("No")

if __name__ == '__main__':
    main()

Python: n=int(input())

for _ in range(n):
    
    a,b,c=map(int,input().split())
    
    if a**2+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a:
        print("YES")
    else:
        print("NO")

Python: N=int(input())
for i in range(0,N):
    a,b,c=map(int,input().split())
    if a**2==b**2+c**2:
        print("YES")
    elif b**2==a**2+c**2:
        print("YES")
    else:
        if c**2==a**2+b**2:
            print("YES")
        else:
            print("NO")
    i+=1