If a pointer is an address, does that mean an expression like p+j
adds j
to the address stored in p
?
Is it better to use array subscripting or pointer arithmetic when traversing through arrays?
Is i[a]
equivalent to a[i]
?
Why is *a
equivalent to a[]
in Function Parameter declaration?
Is it better style to declare an array parameter as *a
or a[]
?
Are *p
and p[]
interchangable for declaring arrays?
Why can’t we pass a
instead of a[0]
to functions that take in int *p
arguments? Don’t both a
and a[0]
point to the beginning of an array?