Hello everyone,
I could not find a proper answer to my question, so here I am.
Could someone explain me the difference between "int *a" and "int (*a)" in c ?
I now that "int *a" is an array (integer pointer) but then,
what is "int (*a)" ?
If someone could help me, I would be very glad,
Thanks for helping me.
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
[SOLVED] int *a and int (*a)
- alansmithee
- Posts: 41
- Joined: 2013-02-02 08:02
Re: int *a and int (*a)
Those two statements are the same thing, the latter form is just more explicit. The parentheses are unnecessary because they group things using the default grouping rules.
Similar to the way "2 + (3 * 4)" is the same as "2 + 3 * 4".
Similar to the way "2 + (3 * 4)" is the same as "2 + 3 * 4".
'alansmithee' is the user formerly known as 'saulgoode'.