3SOLVING PROBLEMS WITH ARRAYS
In the previous chapter, we limited ourselves to scalar variables, that is, variables that can hold only one value at a time. In this chapter, we’ll look at problems using the most common aggregate data structure, the array. Although arrays are simple structures with fundamental limitations, their use greatly magnifies the power of our programs.
In this chapter, we will primarily deal with actual arrays, that is, those declared with the built-in C++ syntax, such as:
int tenIntegerArray[10];
However, the techniques we discuss apply just as well to data structures with similar attributes. The most common of these structures ...
Get Think Like a Programmer now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.