返回列表 發帖
本帖最後由 tonyh 於 2020-11-21 20:55 編輯
  1. #include<iostream>
  2. #include<cstdlib>
  3. using namespace std;
  4. int main()
  5. {
  6.     cout<<"座號\t國文\t英文\t數學"<<endl;
  7.     cout<<"============================"<<endl;
  8.     int a[5][4]={{1,90,85,85},
  9.                  {2,70,75,80},
  10.                  {3,80,95,80},
  11.                  {4,70,95,75},
  12.                  {5,80,85,95}};
  13.     for(int i=0; i<=4; i++)
  14.     {
  15.          for(int j=0; j<=3; j++)
  16.              cout<<a[i][j]<<"\t";
  17.          cout<<endl;
  18.     }
  19.     system("pause");
  20.     return 0;
  21. }
複製代碼

TOP

返回列表