[c]代码库
#include <stdio.h>
int main() {
int a[3][4] = {{1, 3, 5, 7}, {9, 11, 13, 15}, {17, 19, 21, 23}};
int *p = &a[0][0];
// /*
printf("*p=%d\n", *p);
printf("*(p+2)=%d\n\n", *(p + 2));
printf("*(p+4)=%d\n", *(p + 4));
printf("p+4=%d\n\n", p + 4);
printf("a[1]=%d\n", a[1]);
printf("*a[1]=%d\n", *a[1]);
printf("*(a+1)=%d\n", *(a + 1));
printf("*(*(a+1))=%d\n\n", *(*(a + 1)));
printf("a[1][2]=%d\n", a[1][2]);
printf("*(a[1]+2)=%d\n", *(a[1] + 2));
printf("*(*(a+1)+2)=%d\n", *(*(a + 1) + 2));
printf("*(*(a+1+2))=%d\n\n", *(*(a + 1 + 2)));
// */
printf("*a+1=%d\n", *a + 1);
printf("*(a+0)+1=%d\n", *(a + 0) + 1);
printf("a[0]+1=%d\n\n", a[0] + 1);
printf("*(*a+1)=%d\n", *(*a + 1));
printf("*(*(a+0)+1)=%d\n", *(*(a + 0) + 1));
printf("*(a[0]+1)=%d\n", *(a[0] + 1));
}