Variables & Constants

Lesson Instructions

Watch and follow the YouTube video, the lesson contains three parts:

  1. Key Information and content - all you need to do here is watch and listen

  2. Learning activity - this activity involves answering different questions about variables and constants.

  3. Consolidation - these are past exam question and are for deliberate practice to check your understanding.

Task - Identifying Variables & Constants

Task - Exam Questions - Deliberate Practice

Exam Questions - Web

Mark Scheme

Question 1 (a)

1 mark for each bullet point

  • Constant: Pi

  • Variables: WheelSize or Circumference

Question 1 (b)

1 mark for each bullet point

  • The value of a constant is set when the constant is declared

  • The value of a variable is set while the program is running

  • The value of a constant cannot be changed once the program is running/can only be set at dedign time

  • A variable has no value at design time.

Mark as pair:

  • An integer is a whole number

  • A real number can include decimal fractions

Question 2

  • Constant: PlayerKey

  • Variable: Position/KeyPressed