#includeint main(void){ int a=10; int *p = &a; *p = 89; printf("变量值a=%d a=%d\n", a,*p);//0x7fff8af18554 printf("指针地址p=%p p=%p\n",p,&a);//0x7fff8af18554 printf("指针地址p=%#lx p=%#lx\n",p,&a);//0x7fff8af18554 return 0;}
本文共 294 字,大约阅读时间需要 1 分钟。
#includeint main(void){ int a=10; int *p = &a; *p = 89; printf("变量值a=%d a=%d\n", a,*p);//0x7fff8af18554 printf("指针地址p=%p p=%p\n",p,&a);//0x7fff8af18554 printf("指针地址p=%#lx p=%#lx\n",p,&a);//0x7fff8af18554 return 0;}
转载于:https://www.cnblogs.com/wanglijun/p/8503129.html