S
Sac
Hello C Gurus,
Here is one more C behavior which I am not able understand:
int k,*p,*q;
p=&k;
q=p;
when I try to access K by **q compiler throws an error.
However
int a[ ]= {0,1};
int *b[ ] = {a,a+1};
I am able to access a[0] by **b.
As for as I understand array b and q both pointers.
For one pointer to pointer is allowed and for other compiler
gives out an error.
Can somebody enlighten me on this behaviour?
Thanks
Sac
Here is one more C behavior which I am not able understand:
int k,*p,*q;
p=&k;
q=p;
when I try to access K by **q compiler throws an error.
However
int a[ ]= {0,1};
int *b[ ] = {a,a+1};
I am able to access a[0] by **b.
As for as I understand array b and q both pointers.
For one pointer to pointer is allowed and for other compiler
gives out an error.
Can somebody enlighten me on this behaviour?
Thanks
Sac