返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. using namespace std;
  4. int main()
  5. {
  6.     string subject[4]={"座號","國文","英文","數學"};
  7.     int point[5][3]={{90,85,85},
  8.                  {70,75,80},
  9.                  {80,95,80},
  10.                  {70,95,75},
  11.                  {80,85,95}};
  12.     for(int a=0; a<=3; a++)
  13.     {
  14.         cout<<subject[a]<<"\t";
  15.     }
  16.     cout<<endl;
  17.     cout<<"=============================="<<endl;
  18.     for(int t=0; t<=4; t++)
  19.     {
  20.         cout<<t+1<<"\t";
  21.         for(int x=0; x<=2; x++)
  22.         {
  23.              cout<<point[t][x]<<"\t";
  24.         }
  25.         cout<<endl;            
  26.     }
  27.     cout<<endl;
  28.     system("pause");
  29.     return 0;   
  30. }                           
複製代碼

TOP

  1. #include <iostream>
  2. #include <cstdlib>
  3. using namespace std;
  4. int main()
  5. {   
  6.     string subject[4]={"座號","國語","數學","英文"};
  7.     int point[5][3]={{90,100,85},
  8.                      {90,100,85},
  9.                      {90,100,85},
  10.                      {90,100,85},
  11.                      {90,100,85}};      
  12.     for (int a=0;a<4;a++)
  13.     {
  14.        cout<<subject[a]<<"\t";
  15.      }
  16.      cout<<endl;
  17.      cout<<"================================"<<endl;
  18.     system("pause");
  19.     return 0;   
  20. }
複製代碼

TOP

返回列表