Is there any restriction for declaring a pointer variable p1 which holds the address of another pointer variable p2 and so on. | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
0

Is there any restriction for declaring a pointer variable p1 which holds the address of another pointer variable p2 and so on.

ex: int a,*p=&a; int **p1=&p; int ***p3=&p1; // so on... . . .

9th Nov 2016, 2:23 PM
gowtham
gowtham - avatar
1 ответ
0
No restrictions. This is used regularly when you want to "pass" a pointer to some function. Basically you provide "p1" so function can change "p".
9th Nov 2016, 2:26 PM
Sel
Sel - avatar