Book
Collection
Click for Table of Contents
© 2025 by Rance D. Necaise
C Primer for Python Programmers
Copyright © 2025
Rance D. Necaise

10.9 Array of Arrays

Although the allocation of a single array for the storage a 2-D array is quite easy, accessing the individual elements requires the use of the index equation for each access. A second approach that can be used for allocating and accessing a dynamic 2-D array is the use of an array of arrays. In this approach, the allocation requires extra steps, but accessing an individual element is rather simple. In fact, it is no different than accessing an element of a static 2-D array.