问题
单项选择题
下列定义中p指向的地址可更改,但*p不能够更改的是( )。
A.const int *p;
B.int * const p;
C.const int *const p;
D.int * p;
答案
参考答案:A
解析: const int*p:是只能改变指针地址,Int*const p;是只能改变*p的内容,constmt*const p;是指针的地址和*p的内容都不能改变,Int *ps是两者都能改变。