📅  最后修改于: 2022-03-11 14:44:54.079000             🧑  作者: Mango
//The ampersand is used to dereference a pointer variable
int a = 10
int *ptr = &a //points to the location in memory instead of the value (10)
//Additionally, the ampersand can be used to point to another variable like so:
int& b = a // points to the value of a, which is 10
//Run the following code to test
cout << a << endl;
cout << ptr << endl;
cout << b << endl;