Go: package main
import (
        "fmt"
)

func main() {
        var num int
        fmt.Scan(&num)

        for i := 0; i < num; i++ {
                s1 := 0
                s2 := 0
                s3 := 0
                var chk int = 0
                fmt.Scanf("%d %d %d", &s1, &s2, &s3)
                if s1 >= s2 {
                        if s1 > s3 {
                                chk = 1
                        } else {
                                chk = 3
                        }
                } else {
                        if s2 >= s3 {
                                chk = 2
                        } else {
                                chk = 3
                        }
                }

                if (chk == 1 && s1*s1 == s2*s2 + s3*s3) ||
                        (chk == 2 && s2*s2 == s3*s3 + s1*s1) ||
                        (chk == 3 && s3*s3 == s1*s1 + s2*s2) {
                        fmt.Printf("YES\n")
                } else {
                        fmt.Printf("NO\n")
                }
        }
}

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 int(z ** 2) == int(x ** 2) + int(y ** 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_mul = number_1 ** 2
    number_2_mul = number_2 ** 2
    number_3_mul = number_3 ** 2

    if number_1_mul == number_2_mul + number_3_mul:
        print("YES")
    if number_2_mul == number_3_mul + number_1_mul:
        print("YES")
    if number_3_mul == number_1_mul + number_2_mul:
        print("YES")

    else:
        print("NO")

Python: 
N = int(input())
A = []
B = []
C = []#最長辺
for i in range(N):
    a, b, c = map(int, input().split())
    if(a > b):#a,bを昇順に並び替える
        t = a
        a = b
        b = t
    if(b > c):#b,cを昇順に並び替える
        t = b
        b = c
        c = t
    A.append(a)
    B.append(b)
    C.append(c)
for i in range(N):
    if(A[i]**2 + B[i]**2 == C[i]**2):
        print("YES")
    else:
        print("NO")

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

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

Python: 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 A+C==B or B+C==A:
        print("YES")
    else:
        print("NO")

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

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

for i in range(N):
    tri = input()
    tri_list.append(tri.split())
    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: n = int(input())

l = []
for i in range(n):
    line = input()

    numl = line.split(' ')

    numl.sort()
    l.append(numl)

for i in range(n):

    if int(l[i][0]) ** 2 + int(l[i][1]) ** 2 == int(l[i][2]) ** 2:
        print("YES")
    else:
        print("NO")

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

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

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

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

Python: x=input()
i=0
while int(x)>i :
    a,b,c=input().split()
    a=int(a)
    b=int(b)
    c=int(c)
    if a*a==b*b+c*c or b*b==c*c+a*a or c*c==b*b+a*a :
        print("YES")
    else :
        print("NO")
    i=i+1

Python: # coding: utf-8
# Here your code !

import sys
import math

r = sys.stdin.readlines()

n = [[int(i) for i in (j.split())] for j in r]

for i in range(1,n[0][0]+1):
    sq = []
    for a in n[i]:  #a is lengthes
        sq.append(a**2)
    if (sum(sq)-2*max(sq) == 0):
        print("YES")
    else:
        print("NO")

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

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

Python: def sankaku(a,b,c):
    if (a*a)+(b*b)==c*c:
        return "Yes"
    elif (a*a)+(c*c)==b*b:
        return "Yes"
    elif (b*b)+(c*c)==a*a:
        return "Yes"
    else:
        return "No"
    
l = 0
l = input().split()
d = int(l[0])
e = int(l[1])
f = int(l[2])

print(sankaku(d,e,f))

Python: import collections
import sys

def read_prob():
    inputs = []
    try:
        counter = 0
        while True:
            if counter == 0:
                line = input().strip()
                size = int(line)
            else:
                line = input().strip().split()
                a, b, c = line[0], line[1], line[2]
                inputs.append([int(a),  int(b), int(c)])
            counter += 1
    except EOFError:
        pass
    return inputs

def triangle(inputs):
    f = lambda x: x * x
    inputs = list(map(f, inputs))
    # print(inputs)
    a, b, c = inputs[0], inputs[1], inputs[2]
    if a + b == c:
        return True
    elif a + c == b:
        return True
    elif b + c == a:
        return True
    else:
        return False

if __name__ == '__main__':
    inputs = read_prob()
    for inp in inputs:
        if triangle(inp):
            print("YES")
        else:
            print("NO")

Python: N=int(input())

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

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

Python: def is_triangle(x, y, z):
    x, y, z = sorted([x, y, z])
    return x**2 + y**2 == z**2

num = int(input())
for i in range(num):
    x, y, z = map(int, input().split())
    triangle = is_triangle(x, y, z)
    if triangle:
        print('YES')
    else:
        print('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: n = int(input())
L = [input() for i in range(n)]
for line in L:
	A = line.split()
	B = sorted([int(A[i]) for i in range(3)])
	if B[2]**2 == B[0]**2 + B[1]**2:
		print('YES')
	else:
		print('NO')

Python: N = int(input())

for i in range(N) :
    a, b, c = map(int, input().split())
    L = [a, b, c]
    
    m = L.pop(L.index(max(L)))
    s = L[0] ** 2 + L[1] ** 2
    
    if m ** 2 == s :
        print("YES")
    else :
        print("NO")

Python: n = int(input())

for i in range(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")
    elif c**2 == a**2 + b**2:
        print("Yes")
    else:
        print("No")