C语言二维数组怎么初始化?
帮我改正一下这个二位数组的初始化,但不要改动数据。Scorecard[25][25]={0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0...
帮我改正一下这个二位数组的初始化,但不要改动数据。
Scorecard[25][25]={
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,
0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,3,3,3,3,3,3,3,3,3,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,4,4,4,4,4,4,4,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,5,5,5,5,5,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,6,6,6,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,7,7,7,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,7,8,7,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,7,7,7,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,6,6,6,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,5,5,5,5,5,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,4,4,4,4,4,4,4,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,3,3,3,3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1,2,3,4,5,6,7,8,7,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,7,7,7,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,6,6,6,6,6,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,5,5,5,5,5,5,5,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,4,4,4,4,4,4,4,4,4,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,3,3,3,3,3,3,3,3,3,3,3,2,1,0,0,0,0,0,
0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,0,0,0,
0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,}; 展开
3个回答
展开全部
初始化是在数组定义时进行的,根据你的说法,定以后就只能对每个元素单独赋值来实现
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
去掉回括号前面的逗号
更多追问追答
追问
还是不行
追答
你没有声明类型(掉了前面的int)。
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
每一个25数字加一个{}
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询