Chapter 9 Further Reading: Arrays

Primary References

Textbooks

  • Wirth, Niklaus. Algorithms + Data Structures = Programs. Prentice-Hall, 1976. The classic that gives our Theme 5 its name. Wirth's treatment of arrays in Pascal is the definitive original source. Chapters 1-2 cover arrays, searching, and sorting with clarity that has not been surpassed. Available in various reprints and online editions.

  • Dale, Nell and John Lewis. Computer Science Illuminated. 8th ed., Jones & Bartlett, 2020. Chapter 8 provides an excellent language-independent treatment of arrays, including memory layout, multidimensional arrays, and the relationship between arrays and algorithms. Good for understanding arrays as a general concept beyond Pascal.

  • Sedgewick, Robert. Algorithms in Pascal. Addison-Wesley, 1990. Specifically written for Pascal programmers. Covers array-based algorithms (searching, sorting, selection) with rigorous analysis and clear Pascal implementations. The array-based sorting chapters are particularly valuable preparation for later chapters in this textbook.

Free Pascal Documentation

  • Free Pascal Reference Guide. Chapter on Arrays. https://www.freepascal.org/docs-html/ref/refsu14.html The authoritative specification for static arrays, dynamic arrays, open array parameters, and array-of-const. Essential when you need the precise rules for type compatibility, parameter passing, and memory management.

  • Free Pascal Programmer's Guide. Dynamic Arrays. https://www.freepascal.org/docs-html/prog/progse3.html Detailed coverage of dynamic array internals, reference counting, and the behavior of SetLength, Copy, and related operations.

Deeper Exploration

Algorithm Design with Arrays

  • Cormen, Thomas H., et al. Introduction to Algorithms (CLRS). 4th ed., MIT Press, 2022. The standard algorithms textbook. While not Pascal-specific, Chapters 2 (Insertion Sort), 6-8 (Sorting), and 9 (Medians and Order Statistics) all use arrays as the primary data structure. The pseudocode translates readily to Pascal.

  • Knuth, Donald E. The Art of Computer Programming, Volume 3: Sorting and Searching. 2nd ed., Addison-Wesley, 1998. The encyclopedic reference on array-based searching and sorting algorithms. Dense but rewarding. Particularly relevant when we reach sorting in a later chapter.

Memory Layout and Performance

  • Bryant, Randal E. and David R. O'Hallaron. Computer Systems: A Programmer's Perspective. 3rd ed., Pearson, 2016. Chapter 6 covers memory hierarchy and cache effects — the hardware reason why row-major iteration is faster than column-major for 2D arrays. Understanding spatial locality at the hardware level deepens appreciation for array layout decisions.

Historical Context

  • Wirth, Niklaus. "The Programming Language Pascal." Acta Informatica 1, no. 1 (1971): 35-63. The original paper introducing Pascal. Section 9 describes the array type and its design rationale — why Wirth chose to allow arbitrary index types, how arrays interact with the type system, and the philosophy behind compile-time size determination.

  • Jensen, Kathleen and Niklaus Wirth. Pascal User Manual and Report. Springer-Verlag, 1974. The original Pascal language definition. The array sections establish conventions that influenced every subsequent Pascal implementation and many other languages.

Online Resources

  • Pascal Tutorial — Arrays. https://www.tutorialspoint.com/pascal/pascal_arrays.htm A concise tutorial with runnable examples covering static arrays, multidimensional arrays, and dynamic arrays in Free Pascal.

  • Lazarus/Free Pascal Wiki — Arrays. https://wiki.freepascal.org/Array Community-maintained wiki with practical examples, common patterns, and answers to frequently asked questions about array behavior in Free Pascal.

  • Rosetta Code — Array tasks. https://rosettacode.org/wiki/Category:Arrays Side-by-side implementations of array operations in dozens of languages, including Pascal. Excellent for seeing how Pascal's array features compare to other languages.

Before Chapter 10, consider reviewing: - The Free Pascal documentation on records (type ... = record ... end), since arrays of records are the natural evolution of parallel arrays. - Any coverage of structured types in Pascal, which unifies arrays, records, and sets under a common conceptual framework.