Technique – Modular Programming Alternative Conceptions

Summary of Technique

This technique is designed to challenge pupils’ understanding of modular programming, and develop understanding of how data flows in and out of program modules.

It is imperative that pupils know the difference between the internal data flow and external data input/output of the program.  A frequent mistake is to think that data flow is based on user action: e.g. a user entering it from the keyboard or data being loaded from an external file.

The alternative conception is that the pupils are applying the traditional input, process, output to the modular design of their program, rather than seeing data flow as part of the design.

Exercise(s) for Teachers

A list of common alternative conceptions and introductory powerpoint are available below.


Ways of Using the Technique in the Classroom

It is essential that the teacher is clear on the differences between the traditional input, process, output methods and the internal workings of a program environment (parameter passing).


Benefits for Learners

Pupils are more aware of how data is flowing between procedures in their program.  This helps them to isolate where problems are in their code or identifying errors when they do not get the intended outcome from their source code.

Pupils are better prepared for creating their own modular programs with minimal use of global variables. This in turn allows them to create sub-programs that can be reused in new programs and would be fully comfortable with the idea of formal and actual parameters.

Tips for Creating New Exercises

The list of alternative misconceptions is an ideal point to start when creating new questions. It may also help to look at previous materials in order to create generic questions.

Convert into your own teaching language but also make the SQA reference language versions available for pupils to compare.

Making sure pupils understand the language specific nature of data flow is important. Languages have subtly different approaches to data flow – some languages prevent the programmer from choosing between pass by value and pass by reference, for example. Other languages expect a return value from subroutines. Scoping can be different for the same code in different languages.

Pupil Materials


You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *