#include <iostream>
#include <algorithm>
#include <array>

int main(void)
{
	int16_t data_num = 0;
	int16_t first = 0;
	int16_t second = 0;
	int16_t third = 0;
	
	std::cin >> data_num;


	std::array<int16_t, 3> sides;

	for (int i = 0; i < data_num; i++)
	{
		std::cin >> sides[0] >> sides[1] >> sides[2];

		std::sort(sides.begin(), sides.end());
		
		if ( std::pow(sides[2], 2) == (std::pow(sides[0], 2) + std::pow(sides[1], 2)) )
		{
			std::cout << "YES" << std::endl;
		}
		else
		{
			std::cout << "NO" << std::endl;
		}
	}

	return 0;
}