computing programming teaching and learning

Block Model

Learning programming has several challenges:

  • It is concept-rich, leading to cognitive overload
  • It balances comprehension with coding experience
  • It demands persistence and resilience
  • Learners need a secure mental model of computation


If you haven’t done so already, you should study the “PRIMM” model of programming instruction, which suggests five stages of interacting with new code: Predict, Run, Investigate, Modify, Make. You can read more about PRIMM in the Teach Computing quick read at and on the blog

The block model

During the “I” phase of PRIMM, while investigating the code, students should be encouraged to ask questions about it to deepen their understanding. You can prompt them with questions such as:

  • What would happen if you swap lines 2 and 3?
  • What would happen if you give it input of ___?
  • What if you change the symbol on line 5 from > to < ?
  • Line 5 shows a condition-controlled loop, why do we call it this?
  • What will make the loop end?

We can check we are encouraging valuable thought across the whole range of programming skills using an approach called the “block model”. Devised by Carsten Schulte in 2008, the block model has a grid with two axes, one showing the size of the programming element under consideration, and the other the distinction between the structure, execution and function of the program:

If we map our questions and activities onto the block model, we can then identify any gaps. Adding more tasks in those gaps will ensure that we cover the whole grid. In this way we ensure students are thinking hard about the full range of skills required to thoroughly understand a program.

Find out more

Visit to find out more about fostering program comprehension, or read the other principles at And subscribe to Hello World to read much more about computing pedagogy every two months:

The block model is also explained in “Computer Science Education” edited by Sue Sentance and the new version is available now for around £25 here I summarise this principle and many other programming pedagogies in my book “How to Teach Computer Science” available for under £15 here:


Ubiquitous classroom display post

This is not just showing off, I thought this display might be of use to other Computing teachers. The process of designing an algorithm and the ability to transform algorithms from flowchart to pseudocode to program code is vital, so I put it on my wall. Attached is the Word Doc (yes, I knoalgowallw, hardly hi-tech but it works), and the finished picture. Enjoy.


flowchart display