Listing 2 Illustrates pointers to pointers

/* ptr2ptr.c: Pointers to pointers */
#include <stdio.h>

main()
{
   int i = 7;
   int *ip = &i;
   int **ipp = &ip;

   printf("Address %p (i) contains %d\n",ip,*ip);
   printf("Address %p (ip) contains %p\n",ipp,*ipp);
   printf("**ipp == %d\n",**ipp);
   return 0;
}

/* OUTPUT:
 * Address FFF4 (i) contains 7
 * Address FFF2 (ip) contains FFF4
 * **ipp == 7 */

/* End of File */