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