AlgorithmsTopic Summary

Knowledge Organiser: Arrays and Records

Part of Insertion Sort · GCSE GCSE Computer Science revision

This topic summary covers Knowledge Organiser: Arrays and Records within Insertion Sort for GCSE Computer Science. Revise Insertion Sort in Algorithms for GCSE Computer Science with 15 exam-style questions and 10 flashcards. This topic appears regularly enough that it should still be part of a steady revision cycle. It is section 8 of 8 in this topic. Use this topic summary to connect the idea to the wider topic before moving on to questions and flashcards.

Topic position

Section 8 of 8

Practice

15 questions

Recall

10 flashcards

Knowledge Organiser: Arrays and Records

Key Terms
  • Array: A collection of elements of the same data type stored under one variable name
  • Index: The position number used to access an element in an array (starts at 0)
  • 1D array: A single row of elements accessed by one index
  • 2D array: A grid of elements accessed by row and column indices
  • Record: A data structure that groups related fields of different data types together
  • Field: A named piece of data within a record (e.g. name, age, score)
Must-Know Facts
  • Arrays are zero-indexed: the first element is at index 0, last is at index length-1
  • All elements in an array must be the same data type
  • 2D arrays use [row, column] notation — row first
  • Records can store different data types in the same structure
  • Record fields are accessed using dot notation: student1.name
  • Accessing index 10 in an array of 10 elements causes an error (valid: 0–9)
Key Concepts
  • Declare 1D array: array scores[10]
  • Access element: scores[0] = 85
  • Declare 2D array: array grid[3, 4]
  • Access 2D element: grid[1, 2] = "X"
  • Define record: record Student ... name: String ... endrecord
  • Use dot notation: student1.age = 16
Common Mistakes
  • Using 1-based indexing: Arrays are 0-indexed — the first element is at index 0, not 1; the last element in an array of size 10 is at index 9, not 10
  • Accessing an out-of-bounds index: Accessing scores[10] in an array declared as array scores[10] causes a runtime error — valid indices are 0 to 9
  • Storing mixed data types in an array: All elements in an array must be the same data type — use a record if you need to group different types together
  • Confusing arrays and records: Arrays store multiple values of the SAME type; records group related fields of DIFFERENT types (e.g. name as string and age as integer)
  • Getting 2D array notation wrong: 2D arrays use [row, column] — row index comes first; grid[2, 3] means row 2, column 3

Revise this topic interactively on PrepWise — self-test mode, tap-to-reveal definitions, and Common Mistakes from examiners.

Try the interactive Knowledge Organiser — free →

Keep building this topic

Read this section alongside the surrounding pages in Insertion Sort. That gives you the full topic sequence instead of a single isolated revision point.

Practice Questions for Insertion Sort

Which statement best describes how insertion sort works?

  • A. It repeatedly swaps adjacent elements until the list is sorted
  • B. It divides the list in half repeatedly and merges sorted halves
  • C. It takes each element and inserts it into its correct position in the already sorted portion
  • D. It selects the smallest element and swaps it to the front each pass
1 markfoundation

Describe how insertion sort works. Your answer should include how the algorithm processes each element.

3 marksstandard

Quick Recall Flashcards

What is the time complexity of insertion sort?
O(n²) worst/average case, O(n) best case (already sorted)
How does insertion sort work?
Builds sorted list one element at a time by inserting each element into its correct position

15 questions on Insertion Sort — practise free

Instant marking, adaptive difficulty, and 10 spaced repetition flashcards. Free until your GCSEs.

Try PrepWise Free