选择题
9.
下列定义中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的内容,“const inL*constp;”是指针的地址和*p的内容都不能改变,“int*p;”是两者都能改变。
提交答案
关闭