Go: package main

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

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	scanner.Scan()
	n, _ := strconv.Atoi(scanner.Text())
	num := int(n)
	var strs []string
	var a, b, c int
	var res string
	var YES string = "YES"
	var NO string = "NO"
	for i := 0; i < num; i++ {
		scanner.Scan()
		strs = strings.Split(scanner.Text(), " ")
		a, _ = strconv.Atoi(strs[0])
		b, _ = strconv.Atoi(strs[1])
		c, _ = strconv.Atoi(strs[2])

		res = NO
		if c*c == (a*a+b*b) || b*b == (a*a+c*c) || a*a == (b*b+c*c) {
			res = YES
		}
		fmt.Printf("%s\n", res)
	}
}

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: N=int(input())
for i in range(N):
    x,y,z=map(int,input().split())
    if x**2+y**2==z**2:
        print("YES")
    elif x**2+z**2==y**2:
        print("YES")
    elif y**2+z**2==x**2:
        print("YES")
    else:
        print("NO")

Python: num = int(input())
for i in range (num):
    a=input().split()
    if a[0]==a[1] and a[1]==a[2]:
        print("YES")
    else:
        print("NO")

Python: #!/usr/bin/env python3
# -*- coding: utf-8 -*-

def is_right(a, b, c):
    a2 = a*a
    b2 = b*b
    c2 = c*c

    return a2==b2+c2 or b2==c2+a2 or c2==a2+b2

def main():
    N = int(input())

    for _ in range(N):
        a, b, c = map(int, input().split())

        result = is_right(a, b, c)
        print("YES" if result else "NO")

if __name__ == "__main__": main()

Python: N = int(input())
for i in range(N):
	line = input()
	l = [None]*3
	l[0] = int(line.split()[0])
	l[1] = int(line.split()[1])
	l[2] = int(line.split()[2])
	l.sort()
	if l[0]**2+l[1]**2==l[2]**2:
		print("YES")
	else:
		print("NO")

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

Python: for i in range(int(input())):
    a,b,c = sorted(list(map(int,input().split())))

    if a**2 + b**2 == c**2:
        print('YES')
    else:
        print('NO')

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

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

Python: def main():
    n = input()
    li = [input() for _ in n]
    li = sorted(li)
    a,b,c = int(li[0]),int(li[1]),int(li[2])
    if (a ** 2 + b **2) == c**2:
        print("YES")
    else:
        print("NO")

if __name__ == '__main__':
    main()

Python: a=[print(s) for s in map(lambda x:x[0]+x[1]==x[2] and 'YES' or 'NO', [sorted(int(x)**2 for x in raw_input().split(' ')) for i in range(int(raw_input()))])]

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

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

for i in range(N):
    tri = input()
    tri_list.append(tri.split())
    
for i in range(N):
    tri_list[i].sort()
    if int(tri_list[i][2])^2 == int(tri_list[i][0])^2 + int(tri_list[i][1])^2 :
        print("YES")
    else :
        print("NO")

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

Python: N = input()
a = []
answer_list = []

for i in range(N):
    a.append(map(int, raw_input().strip().split()))

for j in range(len(a)):
    number_1 = a[j][0]
    number_2 = a[j][1]
    number_3 = a[j][2]

    number_1 = number_1 ** 2
    number_2 = number_2 ** 2
    number_3 = number_3 ** 2

    if number_1 == number_2 + number_3:
        print("YES")
    if number_2 == number_3 + number_1:
        print("YES")
    if number_3 == number_1 + number_2:
        print("YES")

    else:
        print("NO")

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

Python: N = int(input())

for i in range(N):
    line = input()
    a, b, c = sorted(int(w) for w in line.split())

    if a**2 + b**2 == c**2:
        print('YES')
    else:
        print('NO')

Python: # coding: utf-8
# Your code here!
N=int(input())
for i in range(N):
    a,b,c=map(int,input().split())
    
    a,b,c=sorted([a,b,c])
    
    if a**2+b**2==c**2:
        print('YES')
    else:
        print('NO')

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

Python: print("\n".join("YES" if max(x) * 2 == sum(x) else "NO" for _ in range(int(input())) for x in [list(map(lambda x: int(x)**2, input().split()))]))

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

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

Python: if __name__ == "__main__":
    line = input()
    a = int(line.split(" ")[0])
    b = int(line.split(" ")[1])
    c = int(line.split(" ")[2])
    if (a*a+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a) :
        print("YES")
    else :
        print("NO")
    exit(0)

Python: data = []
n = int(input())
for i in range(n):
    data.append(list(map(int, input().split())))
    data[i] = sorted(data[i])[::-1]

for j in range(n):
    if data[j][0]**2 == data[j][1]**2 + data[j][2]**2:
        print('YES')
    else:
        print('NO')

Python: for _ in[0]*int(input()):
 a,b,c=map(int,sorted(input().split()))
 print(['NO','YES'][a*a+b*b==c*c])

Python: n = int(input())
while n>0:
  l = [int(i) for i in input().split()]
  l.sort()
  if l[0]**2 + l[1] ** 2 == l[2] ** 2:
    print('YES')
  else:
    print('NO')
  n -= 1

Python: import sys


__author__ = 'bisuk'

i = 0
list = []
for line in sys.stdin.readlines():
    # list1 = line.split(" ")
    list.append(line)
    # list.append(int(line.strip("\n")))

# print("N = "+str(list[0]))
#print(list)
for i in range(1, int(list[0]) + 1):
    #print("i="+str(i) + " :" + list[i]),
    list2 = sorted(list[i].strip("\n").split(" "))
    #print(list2)
    if int(list2[0]) * int(list2[0]) + int(list2[1]) * int(list2[1]) == int(list2[2]) * int(list2[2]):
        print("YES")
    else:
        print("NO")

Python: import sys
for e in sys.stdin:
    a, b, c = sorted(map(int, e.split()))
    if a**2 + b**2 == c**2:
        print('YES')
    else:
        print('NO')

Python: n=int(input())
a_list=[]
for i in range(n):
	k=list(map(int,input().split(" ")))
	L,M,N=sorted(k)
	if L**2+M**2==N**2:
		a_list.append("YES")
	else:
		a_list.append("NO")
for i in a_list:
	print(i)

Python: N = int(input())
for i in range(N):
    a = list(map(int, input().split()))
    a = sorted(a)
    x = a[0]
    y = a[1]
    z = a[2]
    if x**2 + y**2 == z**2:
        print("yes")
    else:
        print("no")

Python: 
#!/usr/bin/env python
# coding: utf-8


def is_right_triangle(L):
    L.sort()
    return L[0] ** 2 + L[1] ** 2 == L[2] ** 2


def main():
    input_count = int(raw_input())
    inputs = []
    for i in xrange(input_count):
        L = raw_input().split(" ")
        L = map(long, L)
        inputs.append(L)

    for L in inputs:
        print ("N0", "YES")[is_right_triangle(L)]

if __name__ == '__main__':
    main()

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