#include <iostream>
#include <algorithm>

 using namespace std;

 int main() {
	int num;
	int x,y,z;
	 int answer;
	
	 cin >> num;
	
	 for(int i = 1; i <= num; i++){
		cin >> x >> y >> z;
		 if(x<y)
			 swap(x,y);
		 if(x<z)
			 swap(x,z);
		 if(y<z)
			 swap(y,z);
		
		 if((y*y + z*z)==x*x)
			 cout <<"YES"<<endl;
		 else
			cout << "NO" << endl;
	 }
	
	 return 0;
 }