A pointer holds a memory address. Given a pointer to the right heap location, a function can access storage beyond its own stack frame. This matters when data must be allocated at runtime rather than sized when the function is compiled. section 10.3.4
Returning a dynamic array in C++
A function allocates an array with `ptr = new int[count]`, fills it through `ptr[i]`, and returns `ptr`. Unlike a fixed-size stack array, its size can come from a runtime argument. section 10.3.4
C# normally expresses the same read-and-return task with an `int[]`. Pointer access is also possible, but the array-copy example places it inside an `unsafe` block and uses `fixed` for both arrays. section 10.3.4
Listing 10.10 C# copy array using pointers instead of references
int[] CopyArray(int[] source)
{
int length = source.Length;
int[] target = new int[length]; #1
unsafe #2
{
fixed (int* pSource = source, #3
int* pTarget = target)
{
for (int i = 0; i < length; i++)
{
pTarget[i] = pSource[i]; #4
}
}
}
return target; #5
}
Follow `pSource[i]` and `pTarget[i]` through the copy loop to see where pointers replace ordinary array access. section 10.3.4

