已知三角形的三個邊 求三角形的面積 -- 海倫公式

三角形的三個邊爲 float x,y,z 設一個變量p float p = (x+y+z)/2 三角形的面積爲 sqrt(p*(p-x)*(p-y)*(p-z))
相關文章
相關標籤/搜索