#include <iostream>
using namespace std;

int main(void){
    int line_number;
    int l, m, n;
    
    cin >> line_number; 

    for(int i = 0; i < line_number; i++){
        // gets input
        cin >> l >> m >> n;
        
        // check
        if(l*l+m*m==n*n || m*m+n*n==l*l || n*n+l*l==m*m){
            cout << "YES" << endl;
        } else {
            cout << "NO" << endl;
        }
    }
    return 0;
}

