#include <iostream>
#include <algorithm>
#include <vector>

int main(int argc, char **argv){
	int n = 0;

	std::cin >> n;

	for(int i = 0; i < n; i++){
		std::vector<int> v(3);

		std::cin >> v[0] >> v[1] >> v[2];
		std::sort(v.begin(), v.end());

		if(v[2] * v[2] == v[0] * v[0] + v[1] * v[1]){
			std::cout << "YES";
		}
		else{
			std::cout << "NO";
		}
		std::cout << std::endl;
	}
	return 0;
}