C++

Timeloop 发表于 1年前 · 关联问题 三角形

include

include

using namespace std;

int main(){

int a,b,c; cin>>a>>b>>c; if(a<b)swap(a,b); if(a<c)swap(a,c); if(a>b+c)cout<<"not a triangle"<<endl; else if(a*a==b*b+c*c)cout<<"yes"<<endl; else cout<<"no"<<endl;

return 0;

}