#include<iostream>
#include<cmath>

using namespace std;

int main(void){
  int n;
  int a,b,c;

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