代码整洁之道——童子军军规
作者:互联网
美国童子军一条简单的军规:让营地比你来时更干净。
清理代码也许只是改好一个变量名,拆分一个有点过长的函数,消除一点点重复代码,清理一个嵌套if语句。
这是让项目代码随着时间流逝而越变越好的最专业的做法。
持续改进也是专业性的内在组成部分。
The boy scouts of America has a simple rule: make the camp cleaner than when you arrived.
Cleaning up the code might be as simple as changing a variable name, splitting a function that is a little too long, eliminating a little bit of duplicate code, and cleaning up a nested if statement.
This is the most professional way to make your project code better over time.
Continuous improvement is also an integral part of professionalism.
标签:little,code,童子军,simple,代码,up,军规,make,整洁 来源: https://blog.51cto.com/StephenJava/2936390