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