#include <iostream>
#include <algorithm>
using namespace std;

int main() {
  int n, a[3];
  cin >> n;
  while (n--) {
    for (auto& e : a) cin >> e;
    sort(a, a + 3);
    bool f = a[0] * a[0] + a[1] * a[1] == a[2] * a[2];
    if (f) cout << "YES" << endl;
    else cout << "NO" << endl;
  }
}