Java 杂谈

如何写出无法维护的代码

2019-06-19  本文已影响4人  秃头哥编程
image.png
对,你没看错,本文就是教你怎么写无法维护的代码。

一、程序命名

二、伪装欺诈

for(j=0; j<array_len; j+ =8)
{
    total += array[j+0 ];
    total += array[j+1 ];
    total += array[j+2 ]; /* Main body of
    total += array[j+3]; * loop is unrolled
    total += array[j+4]; * for greater speed.
    total += array[j+5]; */
    total += array[j+6 ];
    total += array[j+7 ];
}

三、文档和注释

四、程序设计

五、测试

六、其他

总之,我们的口号是—— Write Everywhere, Read Nowhere

image.png
上一篇 下一篇

猜你喜欢

热点阅读