Abstract:
Several studies have suggested that the mental structures of programmers of procedural languages have a close relationship ·with a model of structural knowledge known as Programming Plans. However, it is not clear that this is the case for Prolog, specially because this language has important differences when compared to procedural languages. It does not have obvious syntactic cues to mark blocks of code ( begin/end, repeat/until, etc). Also, its powerful primitives (unification and backtracking) and the extensive use of recursion might influence the way programmers comprehend Prolog code in a significant way.
This paper reports an experiment that tries to characterise the nature of the mental models that programmers build when comprehending Prolog code by finding out which of several structural models, Programming Plans among them, are most relevant for the case of this programming language. The results suggest that Prolog Schemas, a construct related to data structure relationships, is of central importance to Prolog programmers. This result contrasts with those obtained for procedural languages, where Programming Plans, a concept related to functional information, seems to be the dominant model.
This paper reports an experiment that tries to characterise the nature of the mental models that programmers build when comprehending Prolog code by finding out which of several structural models, Programming Plans among them, are most relevant for the case of this programming language. The results suggest that Prolog Schemas, a construct related to data structure relationships, is of central importance to Prolog programmers. This result contrasts with those obtained for procedural languages, where Programming Plans, a concept related to functional information, seems to be the dominant model.