#include<iostream>
#include<cstdio>
#include<cmath>
#include<algorithm>

signed main(){
        int n;
        scanf("%d", &n);
        for(int i=0;i<n;i++){
                int a,b,c;
                scanf("%d %d %d",&a,&b,&c);
                int t=std::max({a,b,c});
                if(a*a+b*b+c*c-t*t-t*t==0) printf("YES\n");
                else printf("NO\n");
        }
        return 0;
}