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)
}

C++: #include <iostream>
using namespace std;


int main () {

	int a,b,c,n;
	cin>>n;
	for(int i=0;i<n;i++){
		cin>>a>>b>>c;
		
		if(a>b){
			int temp=a;
			a=b;
			b=temp;
		}
		if (b>c) {
			int t=b;
			b=c;
			c=t;
		}
		if(a>b){
			int d=a;
			a=b;
			b=d;
		}
		if(c*c==a*a+b*b)
			cout << "YES" << endl;
		else{
			cout<< "NO" << endl;
		}
		
	}
		
		
	
    return 0;
}

C++:     #include <iostream>
    using namespace std;
     
    int main() {
    int a,b,c,x=a*a,y=b*b,z=c*c;
    cin>>a>>b>>c;
     
     
    if(x+y==z||x+z==y||y+z==x) {cout<<"YES";}
    else{cout<<"NO";}	
     
    // your code goes here
    	return 0;
    }

C++: #include <iostream>
#include <algorithm>
using namespace std;

int main() {
  int n, a[3];
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[0] >> a[1] >> a[2];
    sort(a, a + 3);
    if (a[0] * a[0] + a[1] * a[1] == a[2] * a[2]) {
      cout << "YES" << endl;
    } else {
      cout << "NO" << endl;
    }
  }
  return 0;
}

C++: #include <iostream>
using namespace std;

bool check_triangle(int a, int b, int c);

int main()
{
	int n;
	int a,b,c;
	cin >> n;
	for(int i=0;i<n;i++) {
		cin >> a >> b >> c;
		if (check_triangle(a,b,c))
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}

	return 0;
}

bool check_triangle(int a, int b, int c)
{
	
	int cc = max(a,(max(b,c)));
	if (cc*cc == a*a + b*b)
		return true;
	else
		return false;		
}

C++: #include<stdio.h>
int main(){
	int N,x,y,z,i;
	scanf("%d",&N);
	for(i=0;i<N;i++){
		scanf("%d %d %d",&x,&y,&z);
		x = x^2;
		y = y^2;
		z = z^2;
			if((x+y)==z||(x+z)==y||(y+z)==x){
				printf("YES\n");
			}
			else {
				printf("NO\n");
			}
		}
	return 0;
}

C++: #include <cstdio>
#include <algorithm>

const int MAX_N=1000;

using namespace std;

int a[MAX_N],b[MAX_N],c[MAX_N];

int main(){
	int n;
	scanf("%d",&n);
	for (int i=0;i<n;i++){
		scanf("%d %d %d",&a[i],&b[i],&c[i]);
	}
	for (int i=0;i<n;i++){
		if (a[i]<b[i]){
			swap(a[i],b[i]);
		}
		if (a[i]<c[i]){
			swap(a[i],c[i]);
		}
		if (a[i]*a[i]==b[i]*b[i]+c[i]*c[i]){
			printf("YES\n");
		}
		else{
			printf("NO\n");
		}
	}
	return 0;
}

C++: #include<iostream>
#include<queue>
using namespace std;

int main()
{
	priority_queue<int> que;
	int n;
	cin >> n;
	for (int i = 0; i < n; i++)
	{
		int a, b, c;
		for (int j = 0; j < 3; j++)
		{
			cin >> a;
			que.push(a);
		}
		a = que.top();
		que.pop();
		b = que.top();
		que.pop();
		c = que.top();
		que.pop();
		if (a - b < c)
			cout << "YES" << endl;
		else
			cout << "NO" << endl;
	}
	return 0;
}

C++: #include <stdio.h>
#include <algorithm>
using namespace std;

int main() {
    int n, l[3];
    scanf("%d", &n);
    while(n--) {
        scanf("%d %d %d", &l[0], &l[1], &l[2]);
        sort(l, l + 3);
        if (l[0]*l[0] + l[1]*l[1] == l[2] * l[2]) {
            puts("YES");
        } else {
            puts("NO");
        }
    }
    return 0;
}

C++: #include<stdio.h>

int main()
{
    long int a,b,c,n,cas,i;
    scanf("%d",&cas);
    for(i=0;i<cas;i++){
    scanf("%ld%ld%ld",&a,&b,&c);

        if(a==b&&b==c)
            printf("NO\n");

        else if(a*a+b*b>=c*c)
            printf("YES\n");
        else
            printf("NO\n");
    }
    return 0;

}

C++: #include<iostream>

int a,b,c,n;

int main(){
	std::cin >> n;
	for(int i=0; i<n; i++){
		std::cin >> a >> b >> c;
		if((a*a + b*b == c*c)||(a*a + c*c == b*b)||(b*b + c*c == a*a))
			std::cout << "YES\n";
		else
			std::cout << "NO\n";
	}
	return 0;
}

C++: #include<iostream>

unsigned short a, b, c;
int m;
bool flag;

int main()
{
	std::cin >> m;
	for(int i = 0;i < m;++i)
	{
		std::cin >> a >> b >> c;
		if (a==0||b==0||c==0)
		{
			continue;
		}

		flag = false;
		if((a*a)+(b*b)==(c*c))
		{
			flag = true;
		}
		else if((a*a)+(c*c)==(b*b))
		{
			flag = true;
		}
		else if((b*b)+(c*c)==(a*a))
		{
			flag = true;
		}
		if(flag==false)
		{
			printf("NO\n");
		}
		else
		{
			printf("YES\n");
		}
	}
	return 0;
}

C++: #include<cstdio>
#include<cmath>

using namespace std;

int main(){
  int num;
  scanf("%d",&num);
  for(int i=0;i<num;++i){
    double in1,in2,in3;
    scanf("%lf %lf %lf",&in1,&in2,&in3);
    if(in1==sqrt(in2*in2+in3*in3)||
    in2==sqrt(in1*in1+in3*in3)||
    in3==sqrt(in1*in1+in2*in2)){
      printf("YES\n");
    }else{
      printf("NO\n");
    }
  }
  
  return 0;
}