#include <stdio.h>

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