|
|
|
|
|
by marcomonteiro
5546 days ago
|
|
It's not the same as (index + arr). arr is a pointer to the beginning address of a series of particular "types". These types have a specific size in memory. Index increments the pointer by (n * size_of(type)). arr[index] == arr + (n * size_of(type)) == (n * size_of(type)) + *arr |
|
C pointer arithmetic already accounts for object sizes.
And it's sizeof, not size_of. And
is completely different from And it's a series of "values".