Program indentation and comprehensibility
Richard J. Miara, Joyce A. Musselman, Juan Antonio Navarro et al. · Communications of the ACM · 1983
The consensus in the programming community is that indentation aids program comprehension, although many studies do not back this up.We tested program comprehension on a Pascal program.Two styles of indentation were used--blocked and nonblocked--in addition to four passible levels of indentation (0, 2, 4, 6 spaces).Both experienced and novice subjects were used.Although the blocking style made no difference, the level of identation had a significant effect on program comprehension.(2--4 spaces had the highest mean score for program comprehension.)We recommend that a moderate level of indentation be used to increase program comprehension and user satisfaction.
Cited by 158 works. doi:10.1145/182.358437 Open-access PDF
Authors
References
- Software Psychology: Human Factors in Computer and Information Systems
- NEATER2
- Software psychology: Human factors in computer and information systems (Winthrop computer systems series)
- Psychological complexity of computer programs
- A methodology for studying the psychological complexity of computer programs.
- Programming in PASCAL
- An automatic formatting program for PASCAL
- An experimental investigation of the effect of program structure on program understanding
- On the formatting of Pascal programs
- Experimental Investigations of Computer Program Debugging and Modification