Skip to content

EWD249 - 58

                   begin
begin of input:          .................
                         .................
begin of manipulation:   .................
                         .................
begin of output:         .................
                         .................
                   end

suggesting to us, when we read the text , what is going to happen next.

Still better, we write:

                   begin
            input:       begin ...............
                               ............... end;
            manipulation:begin ...............
                               ............... end;
            output:      begin ...............
                               ............... end
                   end

where the labels are considered less as markers of points in the program text than as names of regions -as indicated by the bracket pairs "begin - end"- that follow the label, or as names of the three actions in which the computation has been decomposed. But if we take this point of view, the three "labels" are still comments, i.e. explanatory noise for the benefit of the interested (human) reader, whereas I would like to consider them as an integral part of the program. I want my program text to reflect somewhere the fact that the computation has been decomposed into a time-succession of the three actions, whatever form these might take upon closer inspection. A way of doing this is to write somewhere the (textual) succession of the three (abstract) statements

            "input; manipulation; output"

on the understanding that the time-succession of these three actions will indeed be controlled from the above textual succession, whereas the further refinements of these three actions will be given "somewhere else", perhaps separately, but certainly without relative ordering.