Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR C

** in c

// ** is call a double pointer 
// ** is just a pointer to a pointer
char **p1;
char **p2;
// This is an array of characters( char ).
// an arrays first address is considered a pointer.
// thats why you use a double pointer.
char *tables[5] = {"A","B","C","D","E"};

// Point to the beginning of the table array to store the start of the array 
// addresses.  This stores the array address not the array value.
p1 = table;

// This is pointing to the last adderess of the array.
p2 = table[5];

//to get the values from p1 nd p2
printf("this is the value of p1 %s 
", *p1);
printf("this is the value of p2 %s 
", *p2);

// Hope this helped!
		// Happy coding!!
 
PREVIOUS NEXT
Tagged:
ADD COMMENT
Topic
Name
4+1 =