#include <stdio.h>
int main()
{
int arr[3][3]={{1,2,3},{4,5,6},{7,8,9}};
int (*p)[3]=arr;
int i=0;
for(i=0;i<3;i++){
int j=0;
for(j=0;j<3;j++){
printf("%d ", *((*(p+i))+j));
}
printf("\n");
}
return 0;
}
输出的结果:
标签:arr,遍历,int,二维,printf,指针 From: https://www.cnblogs.com/gaoyuangaoyuan/p/17526506.html