How to introduce procedural programming

12 Oct

Procedural programming is not just a way to get more marks, it is the only way to make sense of long programs. Our attention naturally wonders when the program starts to exceed a few screens worth of code. It is a very good idea to split these into chunks of self-contained code that can be repeatedly "called" - linked (like on the Web) to other bits of code.

Think of a book consisting of chapters which are also a way of structuring the material. Procedures are like these chapters. 

Have a look at this PowerPoint presentation setting up some teaching ideas for Procedural Programming and this one, too.

The main sticking points in this topic include parameter passing, the difference in usage of functions and subroutines, as well as accessing global variables and variable scope in general.

Here is a one-page overview of creating flowcharting procedural programming.

And here is a worksheet for a practical task.

* The email will not be published on the website.