返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. using  namespace std;
  4. int main()
  5. {
  6.    
  7.    int x;
  8.    int y;
  9.    cout<<"請輸入X的值"<<endl;
  10.    
  11.    
  12.    
  13.    cin>>x;
  14.    cout<<"請輸入y 值"<<endl;
  15.    
  16.    cin>>y;

  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.    cout<<"x%y="<<x%y<<endl;
  22.       
  23.    
  24.    
  25.    
  26.    
  27.    
  28.    
  29.    
  30.    
  31.    
  32.      system("pause");
  33.      
  34.     return 0;
  35.    
  36.    
  37. }
複製代碼

TOP

返回列表