1 What is an array?* is an aggregate data type that lets us have many variables of the same type through a single identifier.
2. Which index would you use to access the 2nd variable in an array? [1]
3. What can you say about the size of an array? It starts at 0 and ends at N. The array length is the count of the number of variables in the array = N-1.
Part 2
-
How can you initialize an array? Element by element, or by using an initializer list.
-
How can you get the size of an array in bytes? sizeoff(array)
-
How can you use the function sizeof in order to calculate the number of elements in an array? sizeof(array) / sizeof(array[0])
-
What happens when you try to write outside the bounds of the array? UB. Buffer overflow.