If we have code:
int b = 10;
int* a = &b;
std::cout << a << \" \" << &a << \" \";
As the result, the addres
Thanks for you all I knew what's wrong with it.
In fact I created a pointer in memory by int* a = &b; but I thought I didn't so it's my mistake.
But what I thought that you cannot output the address of something that does not exist in memory like cout<<&(&a),the compiler will tell you that "&" operator need a l-value variable.
And if you want to output the address of pointer to a, you define a pointer to pointer variable int **p2p=&a, and then you can cout<<&p2p , it works.