Simple Pointer Example

#include 

int main()
{
   int x = 10;
   int* p = &x;	// p is a pointer to x

   cout << " x = " << x  << endl;;
   cout << "&x = " << &x << endl;
   cout << " p = " << p  << endl;

   return 0;
}

Output

 x = 10
&x = 0x0012FF7C
 p = 0x0012FF7C