Single lesson · Written for OCR A Level (H446)

Trees and binary search trees – OCR A Level Computer Science lesson (H446)

Students learn to use tree vocabulary accurately and build a binary search tree from a sequence of values.

Also in a bundle Data Structures – OCR A Level Computer Science lessons (H446) 15 lessons for £45 · save 25% on buying separately

Lesson 8 of 15 in unit 12.8 Data Structures, taught in Year 12, Spring 2. It answers one big question: Why does a sorted tree find items faster than a list?

By the end, students can use tree vocabulary accurately and build a binary search tree from a sequence of values.

The Build (the main task)
Draw the binary search tree formed when Tillbrook's depot codes are added in the given order, and explain why searching it is faster than searching an unsorted list of the same codes (5 marks).
Support version
The first three nodes drawn, and a decision card for each new value: smaller → left, larger → right.
Challenge
Explain what happens to the tree, and to its search time, if the codes arrive already in alphabetical order.
Real-world link
Tillbrook's hubs and the depots they feed, then its depot codes held in a search tree.
Key words
Tree, Binary search tree and Root, each with a definition, an icon and a common mix-up on the key vocabulary slide.
Misconceptions it tackles
“Every node in a binary search tree has two children”; “A tree can contain a cycle, like any graph”.
OCR H446 specification
1.4.2 (b).

Every lesson follows the same Code & Commerce structure: a Bell Task recall starter, key vocabulary with definitions and icons, short teaching chunks with a check before pupils move on, The Build (one main task), challenge questions that get harder, and an exit question. Answers reveal one at a time on the slides, and everything is editable PowerPoint and Word.

Students can do it all on paper.

Also sold in the Data Structures unit bundle, which includes the medium term plan, and in the full-year and complete-course bundles.

An independent resource written for OCR A Level Computer Science (H446). It is not endorsed by OCR or Cambridge University Press & Assessment. Programming project (NEA) lessons teach general skills on a made-up example project and give supervised time, within JCQ's rules on the help a centre may give.

What's included

  • Slide deck (PowerPoint)
  • Lesson plan (Word)
  • Worksheet (Word)
  • Support worksheet with scaffolds (Word)
  • Single-teacher licence: use and adapt it with your own classes

More for A Level Computer Science

See all

Written for the specifications named. Not endorsed by or affiliated with any exam board.