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