def pythagorean_check(a, b, c)
    check_result =
        if a**2 == b**2 + c**2 || b**2 == a**2 + c**2 || c**2 == a**2 + b**2
            "YES"
        else
            "NO"
        end

    return check_result
end

DATA_NUM = gets.to_i
DATA_NUM.times do
    a, b, c = gets.chomp.split(' ').map!(&:to_i)
    puts pythagorean_check(a, b, c)
end