num = gets

for j in 1..(num.to_i)    
  data = gets
  triangle = data.split(' ').map{|i| i.to_i}.sort
 
  if triangle[0]**2 + triangle[1]**2 == triangle[2]**2
    puts "YES"
  else
    puts "NO"
  end
end