返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. using namespace std;
  4. int main()
  5. {
  6.    int x;
  7.    cout<<"這市一個鄭方形面積計算器:"<<endl;
  8.    
  9.     cout<<"請輸入邊長的值(單位:公分:";
  10.    cin>>x;
  11.    cout<<"請輸入邊的值:";
  12.    cout<<"當正方形邊長的為"<<x<<"公分,他的面積是"<<x*x<<"平方公分"<<endl;

  13.    
  14.     system("pause");
  15.     return 0;

  16. }
複製代碼

TOP

返回列表