Use Pointer to Pointer

Pointer and pointer's pointer


#include <stdio.h>
/*from   w w w.j  a  v  a  2  s .co  m*/
int main(void)
{
  int x, *p, **q;

  x = 10;
  p = &x;
  q = &p;

  printf("%d", **q); /* print the value of x */

  return 0;
}




















Home »
  C Language »
    Language Advanced »




File
Function definition
String
Pointer
Structure
Preprocessing