#include<iostream>
#include<algorithm>
using namespace std;
int main(){
  int edge[3],n;
  cin >>n;
  while(n--){
    cin >>edge[0]>>edge[1]>>edge[2];
    sort(edge,edge+3);
    if(edge[2]*edge[2] == edge[1]*edge[1]+edge[0]*edge[0]){cout <<"YES"<<endl;}
    else{cout <<"NO"<<endl;}
  }
  return 0;
}