Abstract
Early studies of programming and of other more general planning and problem-solving activities emphasized the hierarchical nature of such tasks. For instance, the dominant approach to problem-solving and planning views such processes as top-down focused activities which start from high level goals that are in turn decomposed into achievable actions via a successive refinement process. Similarly, empirical studies of the programming activity have highlighted such top-down and breadth-first decomposition strategies. These processes are also clearly mirrored in prescriptive accounts of the programming task. More recent characterizations of the programming activity present an alternative view—one which emphasizes the broadly opportunistic nature of the programming process. From this perspective, program design is seen to deviate from the top-down, breadth-first model proposed by previous studies. Here, program design is viewed as opportunistic in the sense that elements of the design can be created asynchronously at any level of abstraction within the solution space. Hence, the program design process is seen to be neither decompositionally nor hierarchically levelled, but mediated by the serendipitous and opportunistic discovery of new knowledge and design constraints and so on. The paper presents empirical support for a model of the program design activity which suggests that the programming process can neither be viewed as strictly top-down nor as globally opportunistic. Rather, it is shown that while opportunistic episodes may occur at any point in the evolution of a program, the programming activity itself is hierarchically structured and proceeds in a largely top-down fashion. Program design is seen as a hierarchical goal-directed task with random opportunistic excursions caused largely by simple cognitive failures.

This publication has 27 references indexed in Scilit: