Run ID:139570
提交时间:2025-12-08 10:35:13
#include <iostream> //designed by hu 2025-10 using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; //不能构成三角形 if(a+b<=c || a+c <=b || b+c<=a){ cout<<"No"; return 0; } //肯定可以构成三角形 if(a==b && b==c){ //&& 2个条件同时满足 cout<<"Equilateral Triangle"; } else if( a==b || b==c || a==c){ //||表示只要有一个条件满足即可 cout<<"Isosceles Triangle"; } else if(a*a+b*b == c*c || c*c+b*b == a*a || a*a+c*c == b*b){ cout<<"Right Triangle"; } else{ cout << "Simple Triangle"; } return 0; }