+ 1

Can be assigned pointer to pointer

7th Mar 2019, 6:35 AM
Arpit Jain
Arpit Jain - avatar
4 Answers
+ 4
Why don't you just try it? đŸ€” int n = 69; int *pn = &n, *pm = pn; printf("%d\n", *pm); // 69 int **ppn = pn; // pointer to pointer printf("%d\n", *ppn); // 69 int ***pppn = ppn; // pointer to pointer to pointer printf("%d\n", *pppn); // 69
7th Mar 2019, 7:11 AM
Anna
Anna - avatar
+ 1
Can be more precise with your question? I don't know what you mean...
7th Mar 2019, 6:49 AM
Aaron Eberhardt
Aaron Eberhardt - avatar
+ 1
can we do this Int *p; Int *q; P=q;
7th Mar 2019, 6:57 AM
Arpit Jain
Arpit Jain - avatar
+ 1
Yes you could do this. For example int a; int *p = &a; int *q; q = p; would be correct.
7th Mar 2019, 7:13 AM
Aaron Eberhardt
Aaron Eberhardt - avatar