返回列表 發帖
  1. #include<iostream>
  2. using namespace std;
  3. int main()
  4. {
  5.   float x, y;
  6.   cout<<"請輸入底(公分):"<<endl;
  7.   cin>>x;
  8.   cout<<"請輸入高(公分):"<<endl;
  9.   cin>>y;
  10.   cout<<"三角形底為:"<<x<<"三角形高為:"<<y<<"面積為"
  11.       <<x*y/2;
  12.    system("pause");
  13.    return 0;  
  14. }
複製代碼

TOP

返回列表