Mastery24:: Creation and use of arrays in C++

24 

1017

An array is a series of elements of the same type placed in contiguous memory locations that can be individually referenced by adding an index to a unique identifier.

That means that, for example, five values of type int can be declared as an array without having to declare 5 different variables (each with its own identifier). Instead, using an array, the five int values are stored in contiguous memory locations, and all five can be accessed using the same identifier, with the proper index.

CC BY 4.0 Mastery24:: Creation and use of arrays in C++ by Carolina Romo is licensed under a Creative Commons Attribution 4.0 International License.

Comments are closed.