题解 | 三角形判断

三角形判断

https://www.nowcoder.com/practice/689ec1e742394e09b1059556fc167b65

while True:
    try:
        a,b,c=map(int,input().split())
        if a+b>c and a+c>b and b+c>a:
            if a==b==c:
                print('Equilateral triangle!')
            elif a==b or b==c or a==c:
                print('Isosceles triangle!')
            else:
                print('Ordinary triangle!')
        else:
            print('Not a triangle!')
    except:
        break

全部评论

相关推荐

刷牛客的单身狗很认真:全国可飞,支持007 上班时间,是吧?
点赞 评论 收藏
分享
陌夏微秋:一线城市25w左右吧,17×15=255
点赞 评论 收藏
分享
评论
1
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务