Show me the difference between:
int* v[10];
and
int (*p)[10];
Please.
int* v[10];
This declares v as an array of 10 pointers to int
int (*p)[10];
This declares p as the pointer to array of 10 ints
With
int* v[10];
the variable v
is an array of ten pointers to int
.
The declaration
int (*p)[10];
declares p
to be a pointer to an array of ten int
.