  nano 2.6.1                                                      File: 29.cpp                                                                 

#include <iostream>
#include <sstream>

int main()
{
        unsigned int count=0;
        std::cin>>count;
        std::string* res;
        res=new std::string [count+1];
        for(unsigned int i=0;i<=count;i++)
        {
                std::string str;
                getline(std::cin,str);
                unsigned int a,b,c;
                std::stringstream s(str);
                s>>a>>b>>c;
                if((a*a==b*b+c*c)||(b*b==a*a+c*c)||(c*c==a*a+b*b))
                        res[i]="YES";
                else
                        res[i]="NO";
        }
        for(unsigned int i=1;i<=count;i++)
                std::cout<<res[i]<<std::endl;
        return 0;
}