摘要
面向对象程序设计课程在整个计算机理论和实践教学体系中占据非常重要的地位。很多学生在学完C++课程后,能够初步掌握基本语法和面向对象设计思想,但是编出来的程序质量非常低,程序可读性、稳定性和可重用性非常差,离实际软件开发的要求相差甚远,其中部分原因就是没有好的编程习惯。本文着重就好的C++编程习惯要求和养成做一些探讨,希望通过平时课堂教学和课外实验,学生可以掌握一般的编程风格,养成良好的编程习惯。
The course of Object-Oriented Programming (OOP) is very important in computer theory and practice teaching. A lot of students know some C++ grammar and OOP after finished the whole course. However, the quality of their code is low because its readability, robustness and reusability are bad. It is far from the requirement of software. One of the reasons is that they don't have good programming styles. This article presented what are good programming styles and how to build them. Students can develop good programming styles through normal classes and experiments.
出处
《计算机教育》
2011年第9期64-67,共4页
Computer Education