Examo
PracticeAbout
Homecomputer-scienceArrays
0984

Arrays

Programming · 4 question types

Practise
Download PDF

0984 Topics

Programming Concepts13%
Arrays5%
  1. What an Array Is
  2. Declaring a 1D Array
  3. Reading and Writing Array Elements
  4. Looping Through an Array
  5. 2-Dimensional Arrays
  6. Looping Through a 2D Array
  7. A 2D Array in Action: a TV-watching Log
File Handling3%
Procedures and Functions4%

Frequency legend

High (≥14%)
Above avg (10 to 13%)
Average (<10%)

Exam Frequency Analysis

Past paper frequency (2018 to 2024)

This topic accounts for approximately 5% of your exam marks.

stable
Rare
Stable5%

1D array manipulation with FOR loops appears regularly in Paper 2. 4 to 6 marks.

An array is a named, ordered collection of values of the same data type, stored as a single variable. Each value is accessed using an index.

Three things make arrays different from ordinary variables:

  • One name, many values. Instead of Score1, Score2, Score3, ..., Score30, you can use a single array Scores with 30 elements.
  • Same data type for every element. An array of integers can only hold integers; an array of strings can only hold strings.
  • Fixed size. The size is set when the array is declared and (in CIE pseudocode) does not change.

Arrays are essential because programs almost always need to handle many values at once: a class of students, a row of pixels in an image, a list of stock prices, a sequence of network packets.

Previous

A Reference Card

Next

Declaring a 1D Array