Community resourceWorksheet

OCR H446 2.2.1 Programming techniques consolidation

Part 13 of 14 · H446 2.2.1 · Programming techniques

Consolidation across the whole of H446 2.2.1, built on a hack-day dashboard that mixes control flow, recursion, scope, parameter modes, debugging and object orientation. No new content is introduced, so the demand is selecting the right technique and supporting each explanation with evidence, with the planning support withdrawn as students work through it.

Students will:

  • select an appropriate technique for a task and state a one-line plan for it
  • trace a recursive function and the value it returns
  • identify a range fault in a loop header, explain its effect and correct it
  • implement a class combining stored state, a calculation and a decision
  • justify an object-oriented design in which polymorphism produces type-specific output

Inside: 4 explanation cells, 1 multiple-choice question, 3 written answers, 1 Python task and 1 trace table. 19 marks, about 25 to 40 minutes.

Series: H446 2.2.1 · Programming techniques, part 13 of 14.

Shared by Coding PathwayVerified teacher

  • 10 cells
  • About 30 minutes
  • CC BY-SA 4.0
  • Shared 31 Aug 2026
  • Updated 3 Sept 2026

Preview

The whole resource, exactly as a class sees it. Answers and marking are held back.

Programming techniques consolidation

Complete the sections in order, beginning with retrieval or model selection and then applying the ideas in integrated contexts. No new required knowledge is introduced.

A creative hack-day dashboard mixes every 2.2.1 technique. No new content is introduced.

Retrieval model

Before solving, label each demand: control flow; recursion; scope; modularity/parameters; debugging; or OOP. Then write the smallest relevant model: trace columns, call/base pair, scope boxes, interface arrows or object state.

Worked routing examples: “value unchanged after subprogram” → parameter model/scope; “last item omitted” → loop-bound debugging; “same method, different object behaviour” → polymorphism.

Resume with integrated code and extended explanations when that evidence is secure.

Scaffold fading

For the first two tasks, write the method label and a one-line plan. For the integrated coding task, use constructor → state → calculation → decision → tests. For the final explanations, remove the plan and use knowledge → mechanism → scenario consequence.

Identify the required method before answering.

Multiple choice1 mark

A function changes a local parameter received by value. Which caller-side effect is expected?

  • AThe original scalar remains unchanged.
  • BThe original scalar must change.
  • CEvery global is deleted.
  • DThe function cannot return.
Trace table6 marks

Trace this recursive Python function and its returned value.

Enter a value only when it changes. Keep the listing's order.

Use one row for each pass through the loop. Fill in a box only when that value changes on that row, and leave the rest blank.

ProgramPython
  1. def badge_total(n):
  2. if n <= 1:
  3. return n
  4. return n + badge_total(n - 2)
  5. result = badge_total(5)
  6. print(result)
Trace table with 6 columns
Rown (badge_total)resultReturn valueDepthn <= 1Output
1
2
3
4
5
6
7
8
Written answer3 marks

A loop uses range(1, participant_count) to process participant numbers 1 through participant_count. Identify the fault, its effect and a correction.

Answer all three demands.

Students type their answer here.

Integrate modularity and OOP

Implement Workshop with a title and capacity. spaces(booked) returns capacity - booked, but never below zero. status(booked) returns 'full' when no spaces remain and 'open' otherwise.

Coding task7 marks
class Workshop:
    pass
Written answer4 marks

Choose two IDE features that would help diagnose a wrong status at booked = capacity. Explain a distinct use for each.

Name the feature, action and evidence it reveals.

Students type their answer here.

Written answer4 marks

The dashboard needs several event types with a shared summary method but type-specific output. Recommend an OOP design and explain how polymorphism would be used.

State parent/child roles and the common call.

Students type their answer here.

Review your responses

Use evidence from your completed responses to identify the first state, interface or reasoning link that needs improvement. Correct it and reapply the idea to the integrated context.