- #include<iostream>
- #include<cstdlib>
- using namespace std;
- int main()
- {
- string subject[4]={"座號","國文","英文","數學"};
- int point[5][3]={{90,85,85},
- {70,75,80},
- {80,95,80},
- {70,95,75},
- {80,85,95}};
- for(int a=0; a<=3; a++)
- {
- cout<<subject[a]<<"\t";
- }
- cout<<endl;
- cout<<"=============================="<<endl;
- for(int t=0; t<=4; t++)
- {
- cout<<t+1<<"\t";
- for(int x=0; x<=2; x++)
- {
- cout<<point[t][x]<<"\t";
- }
- cout<<endl;
- }
- cout<<endl;
- system("pause");
- return 0;
- }
複製代碼 |