#include <iostream.h>
void main( )
{
int i = 5 ;
int * j ; // Declaration of Pointer Variable
j = &i ; // Assigning address of variable i to variable j
cout <<" \n Address of i = " << &i ;
cout <<" \n Address of i = " << j ;
cout <<" \n Value of i = " << i ;
cout <<" \n Value of i = " << *(&i) ;
cout <<" \n Value of i = " << *j ;
}
0 comments:
Post a Comment