#include <stdio.h>

int main()
{
    int n, a, b, c, A, B, C;
    scanf("%d", &n);
    for (int i = 0; i < n; i++)
    {
        scanf("%d %d %d", &a, &b, &c);
        A = a * a;
        B = b * b;
        C = c * c;
        if (A + B == C || A + C == B || B + C == A)
        {
            printf("YES\n");
        }
        else
        {
            printf("NO\n");
        }
    }
    return 0;
}
