【发布时间】:2014-04-14 21:20:04
【问题描述】:
我认为这归结为 数据类型 我用于矩阵的内容,但搜索了一段时间后,我似乎无法找到一个明确的答案,它是如何应该看。另一方面,如果您发现其他部分有问题,也请告诉我。谢谢!
#include <stdio.h>
#include <ctype.h>
#include <stdlib.h>
int main () {
double a[][3] = {
{1.,2./3.,3.},
{4.,5.,6.},
{7.,8.,9.}
};
int x, y;
for (x = 0; x < 3; x++) {
printf("\n\t\t");
for (y = 0; y < 3; y++) {
printf("%5d", a[x][y]);
}//End y loop
}//End x loop
printf("\n\n\t");
system("pause");
return 0;
} //End main
代码输出如下:
01610612736 0
0 0 0
0 0 0
按任意键继续。 . .
【问题讨论】: