C++: Data Structures: Physical Structures - Arrays

Physical Grouping

Structs (Records)
Grouping different types of elements in fields accessed by name is important, yet there is little algorithmically interesting in most programming languages about accessing the fields since they are simply accessed by name. This type of structure does get more interesting when it's implemented in a relational database and manipulated with SQL. The other extension of structs that is interesting is class, which will be revisited below.
Arrays
Arrays of same type elements at are accessed by number are bound very closely to the hardware in that elements are stored in consecutive memory locations. This is a source of both great efficiency and numerous problems. Arrays are algorithmically interesting and much attention is devoted to such issues as sorting, searching, insertion, and deletion.

The problem with physical grouping (arrays)

Using physical grouping such as arrays has a very high price. The programmer is always faced with the problem of what to do when the array is full and there is more data. There are several approaches, each with its own serious problems: