返回列表 發帖
  1. #include<cstdlib>
  2. using namespace std;
  3. int main()
  4. {
  5.   
  6.   int   x, y;
  7.   
  8.   
  9.   cout<<"請輸入一整數x: " ;
  10.    cin>>x;
  11.   
  12.     cout<<"請輸入一整數y";
  13.      
  14.   cin>>y;
  15.   
  16.   cout<<"x+y="<<x+y<<endl;
  17.   cout<<"x-y="<<x-y<<endl;
  18.   cout<<"x*y="<<x*y<<endl;
  19.   cout<<"x/y="<<x/y<<endl;
  20.   cout<<"x%y="<<x%y<<endl;
  21.   system("pause");
  22.   return 0 ;
  23. }
複製代碼

TOP

返回列表