← VCE Pseudocode

Arrays in pseudocode

Accesses the array element at index 1, using square brackets to specify the position.

Understanding Arrays in pseudocode in VCE Pseudocode

What it does: This is exactly how a 5-element integer array is declared. This loop visits each index from 1 to 5 in turn. Square brackets are used to access array elements. The ← symbol assigns a value, just like with normal variables. END FOR closes a FOR loop block correctly. A FOR loop with the array's size lets you visit every element. By convention, indexing starts from 1, not 0. This line stores 10 at index 1 of the scores array.

Common mistakes: Arrays are declared with DECLARE, not ARRAY, in VCAA pseudocode. Array elements use square brackets, not round brackets.

Class: _____________________  ·  Name: _____________________  ·  Date: _________

Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.

This module's key terms are also in a printable crossword (Modules 11–28) and word search (Modules 1–28).

Take this worksheet further — free with Cloodit

Each concept is reinforced from every angle — learned, then applied, then tested.

Learning
Duo
Do array elements use square brackets like scores[1]?
YesNo
Matches
scores(1) ← 10
↓
Wrong - array elements use square brackets, not round
Applying
Meanings
Term
scores[1]
Meaning
Accesses the array element at index 1, using square brackets to specify the position.
Practice
BEGIN
Testing
Gaps
DECLARE scores[5] OF
Check Answer
Spots
1ARRAY scores[5] OF INTEGER
2scores[1] ← 10

Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.

The 'Spider' badge — Web Weaver, one of Cloodit's 106 collectible badges
Students earn collectable badges

Over 100 of them, across seven natural biomes.

Study Buddy
Students build a real study resource

Turns their work into revision material ready for Flash Cards and Exam study.

Diamond Dash — one of Cloodit's live, competitive Sprint games
Students lock in with Sprints

Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.

A Cloodit certificate of achievement, ready to personalise and print
Custom printable certificates

Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.

Quick Questions

1. Do array elements use square brackets like scores[1]?
A. No
B. Yes ✓
Square brackets are used to access array elements.
2. Is round-bracket syntax like scores(1) valid for arrays?
A. No ✓
B. Yes
Round brackets aren't used for array indexing in pseudocode.
3. Does DECLARE scores[5] OF INTEGER declare an array of 5 integers?
A. Yes ✓
B. No
The number in brackets sets how many elements the array holds.
4. Is the ← arrow used to assign values to array elements?
A. Yes ✓
B. No
The ← symbol assigns a value, just like with normal variables.
5. Does a FOR loop over an array end with END FOR?
A. No
B. Yes ✓
END FOR closes a FOR loop block correctly.

Match the Pairs

scores[1] ← 10 → Assigns the value 10 to the first array element
DISPLAY scores[i] → Prints the value stored at index i in the array
Declares an array of 5 integers named scores → DECLARE scores[5] OF INTEGER
Loops through every index in the array → FOR i FROM 1 TO 5
scores(1) ← 10 → Wrong - array elements use square brackets, not round
DECLARE scores OF INTEGER → Wrong - array declarations need a size in brackets

Key Term

scores[1]
Accesses the array element at index 1, using square brackets to specify the position.

Fill in the Blanks

1. DECLARE scores[5] OF INTEGER
Hint: Type the data type stored in the array.
2. DISPLAY scores[i]
Hint: Type the loop variable used as the index.
3. FOR i FROM 1 TO 5
Hint: Type the starting index number used when looping through an array.
4. DISPLAY scores[2]
Hint: Type the keyword used to output a value.
5. DECLARE scores[5] OF INTEGER
Hint: Type the number of elements the array holds.

Spot the Error

Question 1
A ARRAY scores[5] OF INTEGER
B scores[1] ← 10
C DISPLAY scores[1]
Line A — Arrays are declared with DECLARE, not ARRAY, in VCAA pseudocode.
Question 2
A DECLARE scores[5] OF INTEGER
B scores(1) ← 10
C DISPLAY scores[1]
Line B — Array elements use square brackets, not round brackets.
Question 3
A DECLARE scores[5] OF INTEGER
B scores[1] ← 10
C DISPLAY score[1]
Line C — The array name is misspelled - it should be scores, not score.
Question 4
A DECLARE scores[5] OF INTEGER
B FOR i FROM 1 TO 5
C DISPLAY scores[i]
D END LOOP
Line D — A FOR loop must close with END FOR, not END LOOP.
Question 5
A DECLARE scores OF INTEGER
B scores[1] ← 10
C FOR i FROM 1 TO 5
D DISPLAY scores[i]
Line A — An array declaration needs a size in square brackets, like scores[5].

Student with a class code? Join your class →