Lesson Plan

Lesson Plan
Grade: Date: 17/01/2026
Subject: Computer Science
Lesson Topic: Show understanding of the purpose of state-transition diagrams to document an algorithm
Learning Objective/s:
  • Describe the purpose and key components of a state‑transition diagram.
  • Identify states, transitions, initial and final states in a given algorithm.
  • Construct a correct state‑transition diagram for a simple problem.
  • Evaluate a diagram for completeness and determinism.
  • Explain how STDs support testing and communication among developers.
Materials Needed:
  • Projector or interactive whiteboard
  • Printed handout with the login algorithm description
  • Whiteboard markers and eraser
  • Sticky notes or index cards for state/transition cards
  • Laptops with diagramming software (e.g., draw.io) or paper for sketching
Introduction:
Begin with a quick poll: who has ever drawn a flowchart for a program? Explain that today we’ll focus on state‑transition diagrams, a visual tool that captures an algorithm’s states and how they change. Students will learn the essential symbols and how to build a diagram before coding. Success will be measured by correctly creating a diagram for a login system.
Lesson Structure:
  1. Do‑Now (5’) – Students list possible states of a simple login process on sticky notes.
  2. Mini‑lecture (10’) – Introduce STDs, key elements, and notation using the projector.
  3. Guided practice (15’) – Whole class builds the login diagram step‑by‑step, modelling each construction stage.
  4. Collaborative activity (15’) – Small groups receive a new scenario (e.g., vending machine) and create their own diagram on paper or laptop; teacher circulates for feedback.
  5. Peer review (5’) – Groups exchange diagrams, check for missing initial/final states and deterministic transitions using a checklist.
  6. Whole‑class debrief (5’) – Highlight common mistakes and link diagrams to testing.
Conclusion:
Summarise how state‑transition diagrams clarify control flow and aid testing. For the exit ticket, each student writes one benefit of using an STD and one common mistake to avoid. Homework: design an STD for a traffic‑light controller and be ready to share.