Mega Code Archive
Printing the address stored in a char variable
#include
using namespace std;
int main()
{
char *string = "test";
cout << "Value of string is: " << string
<< "\nValue of static_cast< void *>( string ) is: "
<< static_cast< void *>( string ) << endl;
return 0;
}