I'm not sure about the difference between *p[5] and (*p)[5]?
Please help me clarify them?
Thanks a lot!

It turns out that this can be done and that
int (*p1d)[5];

is the proper declaration, i.e. p1d here is a pointer to an array of 5 integers just as it was
under the declaration using the Array type. Note that this is different from

int *p1d[5];

which would make p1d the name of an array of 5 pointers to type int.

which would make p1d the name of an array of 5 pointers to type int.

this one

int *p1d[5];
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.