The quality of software produced by students is often poor. How to teach students to develop good quality software has long been a topic in computer science education and research. We must conclude that we still do not have a good answer to this question. Specifications are necessary to determine the correctness of software, to develop error-free software and to write complete tests. Several attempts have been made to teach students to write specifications before writing code. So far, that has not proven to be very successful: Students do not like to write a specification and do not see the benefits of writing specifications. In this paper we focus on the use of informal specifications. Instead of teaching students how to write specifications, we teach them how to use informal specifications to develop correct software. The results were surprising: the number of errors in software and the completeness of tests both improved considerably and, most importantly, students really appreciate the specifications. We think that if students appreciate specification, we have a key to teach them how to specify and to appreciate its value.
翻译:学生生成的软件质量通常较差。如何培养学生开发高质量软件一直是计算机科学教育与研究的长期课题。我们必须承认,对此问题尚未找到理想答案。规格说明对于确定软件正确性、开发无差错软件及编写完整测试至关重要。学界曾多次尝试教授学生在编写代码前撰写规格说明,但迄今为止成效有限:学生既不愿撰写规格说明,也未能认识到其价值。本文聚焦于非正式规格说明的应用,通过教导学生利用非正式规格说明开发正确软件,而非教授撰写规格说明的方法。研究结果令人惊喜:软件错误数量与测试完整性均显著改善,更重要的是,学生对规格说明产生了高度认可。我们认为,当学生认可规格说明时,便掌握了教授其规范编写方法并领悟规格说明价值的关键。