#include <iostream>
using namespace std;
int main(void){
  int a, b, c, num;
  cin >> num;
  
  for(int i = 0; i < num; i++) {
    cin >> a >> b >> c;
    if(a < b) {
      int temp = a;
      a = b;
      b = temp;
    }
    if(a < c) {
      int temp = a;
      a = c;
      c = temp;
    }
    
    if(a * a == b * b + c * c) {
      cout << "YES" << endl;
    } else {
      cout << "NO" << endl;
    }
  }
}