- Arrays are interpreted as pointers to their first value - Using an array without any iteration returns the address of the first value
plmust be a reference because we cannot copy arrays- With arrays, when you add a number to the array object itself, it advances forward that many times and 'points' to the equivalent entry - If
nis the number in question, thenia[n]is the same as*(ia+n)(We're dereferencing the address that'sn'entriesentries forward), andia+nis the same as&ia[n](We're getting the address of the that entry in the array).
int ia[3][4] = {{1,2,3,4},{5,6,7,8},{9,10,11,12}}; for (int n = 0, *pl;0; n != 3; ++n) plauto &pl = ia[n];