#include <bits/stdc++.h>
using namespace std;

int main(){
  int N; cin >> N;

  for(int i=0; i<N; i++){
    vector<int> l(3);
    cin >> l[0] >> l[1] >> l[2];
    sort(l.begin(), l.end());

    if(l[2]*l[2] == (l[1]*l[1] + l[0]*l[0])){
      cout << "YES" << endl;
    } else {
      cout << "NO" << endl;
    }
  }
}
