/* Is it a Right Triangle? */

#include <iostream>
using namespace std;

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

  for (int i = 0; i < n; i++) {
    int a, b, c;
    int result;
    cin >> a >> b >> c;
    if (a >= b && a >= c) result = a * a - (b * b + c * c);
    else if (b >= a && b >= c) result = b * b - (a * a + c * c);
    else result = c * c - (a * a + b * b);

    if (result == 0) cout << "YES" << endl;
    else cout << "NO" << endl;
  }

  return 0;
}
