Run ID:160966
提交时间:2026-09-26 17:24:21
#include<bits/stdc++.h> using namespace std; int main(){ int t,a,b,c; cin>>t; for (int i=0;i<t;i++){ cin>>a>>b>>c; if (a*a+b*b==c*c || b*b+c*c==a*a || a*a+c*c==b*b){ cout<<"good"<<endl; } else if (a==b || a==c || c==b){ cout<<"perfect"<<endl; } else{ cout<<"just a triangle"<<endl; } } return 0; }