#include <stdio.h>
int main(){
	int n, a, b, c, temp;
	scanf("%d", &n);
	for(int i = 0; i < n; i++){
		scanf("%d %d %d", &a, &b, &c);
		if(a > b){
			if(c > a){
				temp = c;
				c = a;
				a = temp;
			}
		}else{
			if(c > b){
				temp = c;
				c = a;
				a = temp;
			}else{
				temp = b;
				b = a;
				a = temp;
			}
		}
		if(b*b + c*c == a*a){
			printf("YES\n");
		}else{
			printf("NO\n");
		}
	}
	return 0;
}