#include using namespace std ; int main() { int num = 100 ; //A normal pointer ptr1 int *ptr1; //This pointer ptr1 is a double pointer int **double_ptr; /* Assigning the address of variable num to the * pointer ptr1 */ ptr1 = &num ; /* Assigning the address of pointer ptr1 to the * pointer-to-pointer double_ptr */ double_ptr = &ptr1; /* Possible ways to find value of variable num*/ printf("\n Value of num is: %d", num); printf("\n Value of num using ptr1 is: %d", *ptr1); printf("\n Value of num using double_ptr is: %d", **double_ptr); /*Possible ways to find address of num*/ printf("\n Address of num is: %p", &num); printf("\n Address of num using ptr1 is: %p", ptr1); printf("\n Address of num using double_ptr is: %p", *double_ptr); /*Find value of pointer*/ printf("\n Value of Pointer ptr1 is: %p", ptr1); printf("\n Value of Pointer ptr1 using double_ptr is: %p", *double_ptr); /*Ways to find address of pointer*/ printf("\n Address of Pointer ptr1 is:%p",&ptr1); printf("\n Address of Pointer ptr1 using double_ptr is:%p",double_ptr); /*Double pointer value and address*/ printf("\n Value of Pointer double_ptr is:%p",double_ptr); printf("\n Address of Pointer double_ptr is:%p",&double_ptr); return 0; }