level 9
#include<iostream>
using namespace std;
int a,b;
int c,d;
class unit{
public:
int x;
int y;
};
int main()
{
c=2;
d=3;
unit unit[c][d];
for (a=1;a<3;a++)
{
for (b=1;b<4;b++)
{
unit[a][b].x=a;
cout<<unit[a][b].x;
unit[a][b].y=b;
}
}
//cout<<unit[1][1].x<<"\n";
//cout<<unit[1][1].y;
}
2016年09月26日 15点09分
3
level 9
unit没有变色,不知道是不是保留字,二维数组我申请的空间应该是够的
2016年09月27日 14点09分
5