Such a quick, odd question: I passed the exam, and the question was:
char c = 'A' char *p =&c char **p2 = &p void *v = &p2
Enter the type (i.e. int, void *, etc.) of the following expression:
I replied:
and lost full credit. I just wanted to get a second opinion from someone before trying to get the points back.
I was not sure about this, but I thought that since v was a void pointer to a memory address, v would be void** . If v were dereferenced, it would be char**** .
p2 is char** , so adding 1 to it will still make it char** .
v[0] does not exist.
If someone could help me with such a stupid problem, I would be very grateful. Thanks.
source share