
#計算三角形的面積
#第一步先輸入三個邊長的值
# a = float(input("輸入三角形第一邊長:"))
# b = float(input("輸入三角形第二邊長:"))
# c = float(input("輸入三角形第三邊長:"))
#第二步判斷是否構成三角形
# while a + b < c or b + c < a or b + c < a:
# print("輸入的邊不構成三角形,請重新輸入")
# a = float(input("輸入三角形第一邊長:"))
# b = float(input("輸入三角形第二邊長:"))
# c = float(input("輸入三角形第三邊長:"))
# #第三步計算三角形的面積
# c1 = (a + b + c)/2
# s=(c1*(c1-a)*(c1-b)*(c1-c))**0.5
# print("三角形的面積為:%0.2f"%s)
