int a[3][4] = { 0, 1,2,3,4,5,6,7,8,9,11,12}; printf("\n%d,%d", a,*a); //两个一样的16进制地址 printf("\n%d,%d", sizeof(a), sizeof(*a)); // 48 16 printf("\n%d,%d", a[0],*(a+0)); //两个一样的16进制地址 printf("\n%d,%d", sizeof(a[0]), sizeof(*(a+0))); //16 16 printf("\n%d,%d", &a[0],&a[0][0]); //两个一样的16进制地址 printf("\n%d,%d", sizeof(a[0]), sizeof(a[0][0])); // 16 4 printf("\n%d,%d", a[1],a+1); //两个一样的16进制地址 printf("\n%d,%d", sizeof(a[1]), sizeof(a+1)); // 16 4 printf("\n%d,%d", &a[1][0],*(a+1)+0); //两个一样的16进制地址 printf("\n%d,%d", sizeof(&a[1][0]), sizeof(*(a+1))); //4,16 printf("\n%d,%d", a[2],*(a+2)); //两个一样的16进制地址 printf("\n%d,%d", sizeof(a[2]), sizeof(*(a+2))); // 16 16 printf("\n%d,%d", &a[2],(a+2)); //两个一样的16进制地址 printf("\n%d,%d", sizeof(&a[2]), sizeof(a+2)); //4 4 printf("\n%d,%d", a[1][0],*(*(a+1)+0));//5 5 printf("\n%d,%d", *a[2],*(*(a+2)+0)); // 8 8 getchar();
时间: 2024-10-11 00:12:06