for i in range(int(input())):
    n = [int(i) for i in input().split(" ")]
    n.sort()
    print("YES" if n[0] * n[0] + n[1] * n[1] == n[2] * n[2] else "NO") for i in range(int(input())):
    n = [int(i) for i in input().split(" ")]
    n.sort()
    print("YES" if n[0] * n[0] + n[1] * n[1] == n[2] * n[2] else "NO") i range(int(input())) range int(input()) int input() input int(i) for i in input().split(" ") for i in input().split(" ") i input().split(" ") ().split () input split " " for i in input().split(" ") int(i) int i n = [int(i) for i in input().split(" ")] n [int(i) for i in input().split(" ")] n.sort() n.sort n sort print("YES" if n[0] * n[0] + n[1] * n[1] == n[2] * n[2] else "NO") print "YES" if n[0] * n[0] + n[1] * n[1] == n[2] * n[2] else "NO" n[0] * n[0] + n[1] * n[1] == n[2] * n[2] n[0] * n[0] + n[1] * n[1] n[0] * n[0] n[0] n 0 n[0] n 0 n[1] * n[1] n[1] n 1 n[1] n 1 n[2] * n[2] n[2] n 2 n[2] n 2 "YES" "NO" n = [int(i) for i in input().split(" ")] [int(i) for i in input().split(" ")] n
for i in range(int(input())):
    n = [int(i) for i in input().split(" ")]
    n.sort()
    print("YES" if n[0] * n[0] + n[1] * n[1] == n[2] * n[2] else "NO")