N=gets.to_i
N.times do
  length_list =  gets().split().map(&:to_i).to_a

  if length_list.max != length_list.min
    hypotenuse = length_list.max
  else
    puts "NO"
    next
  end

  cathetus_list = length_list - [hypotenuse]

  if (hypotenuse**2) == (cathetus_list[0]**2 + cathetus_list[1]**2)
    puts "YES"
  else
    puts "NO"
  end
end