输出对角线的数值

 

eg:

 

#include <stdio.h>
main()
{   int a[3][3]={0,1,2,3,4,5,6,7,8},(*p)[3],i;
    p=a;
    for(i=0;i<3;i++)
    {  printf("%d ",(*p)[i]); p++; }
}

原文地址:https://www.cnblogs.com/wven/p/13275519.html