What exactly is the relationship between pointers and arrays in C++?

353 views

Like, why is it that sometimes, when a function input is supposed to be a pointer, you can use an array instead?

In: 0

3 Answers

Anonymous 0 Comments

An array object is a pointer to a serialized list of objects. So if a function takes a pointer, it can take an “array,” because you aren’t passing the array, just the pointer to the array.

You are viewing 1 out of 3 answers, click here to view all answers.