返回列表 發帖
#include<iostream>
#include<cstdlib>
using namespace std;
int main(){
        float t,m;
        cout<<"請輸入三角形的底:"<<endl;
        cin>>t;
        cout<<"請輸入三角形的高";
        cin>>m;
        cout<<"底"<<t<<"高"<<m<<",算的面積是"<<t*m/2<<end1;
        system("pause");
    return 0;
}

TOP

返回列表