int a = 0;
const int a = 0;
int const a = 0;
int num = 10;
const int* p1 = #
const int* p2;
p2 = #
//*p2 = 7; // 不能通过指针改变被指向对象的值
int num = 10;
int* const p3 = #
//int* const p4 = NULL; //必须初始化
//p4 = # //不能赋值
*p3 = 9;
cout << num << endl;
int num = 10;
const int* const pp = # //必须初始化
//*pp = 3; // 不能通过指针改变被指向对象的值
原文:https://www.cnblogs.com/ZhenXin0101/p/13524864.html