📜  “编写代码以更改指针的值.编写代码以更改指针指向的值” - 无论代码示例

📅  最后修改于: 2022-03-11 14:56:13.478000             🧑  作者: Mango

代码示例1
int a = 0, b = 1;
int *p1 = &a, *p2 = p1;

// change the value of a pointer.
p1 = &b;
// change the value to which the pointer points
*p2 = b;