문제

char const*const variablename = " ";

what does it mean?

is it same as pointer declaration?

Please anyone explain.

Thank you in advance!

도움이 되었습니까?

해결책

It's a const pointer to a const C string. This means that neither the contents of the string, nor the pointer itself, can be changed.

다른 팁

const protects his left side, unless there is nothing to his left and only then it protects his right side.

Applying this to your example, it's a const pointer to a const String.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top