count = gets.to_i

for i in 1..count

	a = gets
	a = a.split(" ")
	a[0] = a[0].to_i
	a[1] = a[1].to_i
	a[2] = a[2].to_i
	
	a = a.sort
	
	if a[2]*a[2] ==a[0]*a[0]+a[1]*a[1]
		puts "YES"
	else
		puts "NO"
	end	
end