Inculcating invariants in introductory courses

  • Authors:
  • David Evans;Michael Peck

  • Affiliations:
  • University of Virginia;Johns Hopkins University

  • Venue:
  • Proceedings of the 28th international conference on Software engineering
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

One goal of introductory software engineering courses is to motivate and instill good software engineering habits. Unfortunately, practical constraints on typical courses often lead to student experiences that are antithetical to that goal: instead of working in large teams and dealing with changing requirements and maintaining programs over many years, courses generally involve students working alone or in small teams with short projects that end the first time the program works correctly on some selected input. Small projects tend to reinforce poor software engineering practices. Since the programs are small enough to manage cognitively in ad hoc ways, effort spent more precisely documenting assumptions seems wasteful. It is infeasible to carry out full industrial software development within the context of a typical university course. However, it is possible to simulate some aspects of safety critical software engineering in an introductory software engineering course. This paper describes an approach that focuses on thinking about and precisely documenting invariants, and checking invariants using lightweight analysis tools. We describe how assignments were designed to emphasize the importance of invariants and to incorporate program analysis tools with typical software engineering material and report on results from an experiment measuring students understanding of program invariants.