import java.util.Scanner

import scala.collection.mutable.ListBuffer

object Main {
  def main(args : Array[String]) = {
    val scanner = new Scanner(System.in)
    val N = scanner.nextLine().toInt
    var inputs = ListBuffer.empty[Array[Int]]
    for(i <- 1 to N){
      inputs += scanner.nextLine().split(" ").map(_.toInt).sorted
    }

    inputs.foreach{
      case Array(a,b,c) =>
        if(Math.pow(c, 2) == Math.pow(a, 2) + Math.pow(b, 2)) {
          println("YES")
        }else{
          println("NO")
        }
    }
  }
}