const for values that never change
Declares a variable whose value is set once and cannot be reassigned. Use it for fixed values like a maximum score. Changing it later causes a TypeError.
Understanding const for values that never change in ACARA Digital Technologies Years 7–8
What it does: A fixed number of rounds is set once, so const is the right choice. The score goes up during the game, so it must be declared with let so it can be reassigned. The keyword const comes first, then the name, then = and the value. A const cannot be reassigned. JavaScript stops the program with a TypeError. If a value will change later, use let. A const would cause a TypeError when you update it. A const is set once, at the moment it is declared. You cannot leave it empty and fill it in later. A running total changes each time, so let is the correct keyword and const causes a TypeError.
Common mistakes: MAX_SCORE was declared with const, so it cannot be reassigned. This causes a TypeError. The line should cap the score: score = MAX_SCORE;. radius changes on the next line, so it must be declared with let. With const, radius = radius * 2 would cause a TypeError. It should be let radius = 5;.
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 562–580) and word search (Modules 522–580).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
constFill in the Blanks
Spot the Error
Student with a class code? Join your class →