这绝对是主观的,但我想尽量避免它变成争论。我认为如果人们恰当地对待它,这将是一个有趣的问题。

这个问题的想法来自于我对“你最讨厌的语言的哪五件事?”问题的回答。我认为c#中的类在默认情况下应该是密封的——我不会把我的理由放在这个问题上,但我可能会写一个更完整的解释来回答这个问题。我对评论中的讨论热度感到惊讶(目前有25条评论)。

那么,你有什么有争议的观点?我宁愿避免那些基于相对较少的基础而导致相当宗教的事情(例如,大括号放置),但例如可能包括“单元测试实际上并没有多大帮助”或“公共字段确实是可以的”之类的事情。重要的是(至少对我来说)你的观点背后是有理由的。

请提出你的观点和理由——我鼓励人们投票给那些有充分论证和有趣的观点,不管你是否恰好同意这些观点。


当前回答

QA应该比开发人员更了解代码(间接地)。QA通过发现开发人员不希望发生的事情而获得报酬,他们经常这样做。(顺便说一句,我是一名非常看重优秀QA人员的开发者。很少)。

其他回答

我真的不喜欢当人们告诉我使用getter和setter而不是使变量公共时,你应该能够获得和设置类变量。

我完全同意如果是改变对象中的一个变量在你的对象中,你不会得到这样的东西:a.b.c.d.e = something;但我更愿意使用:a.x = something;然后a.setX(东西);我认为a.x =某物;实际上,在同一个例子中,它们都更容易阅读,而且比设置/获取更漂亮。

我不明白为什么要这样做:

void setX(T x) { 这个->x = x; }

T getX () { 返回x; }

这就需要更多的代码,需要更多的时间,你要一遍又一遍地做,这只会让代码更难阅读。

工具、方法论、模式、框架等等都不能代替一个训练有素的程序员

我厌倦了与那些认为最新的工具、方法、模式或框架是一颗银弹的人(主要是经理)打交道,他们可以消除雇佣有经验的开发人员来编写软件的需求。不过,作为一名以拯救风险项目为生的顾问,我不应该抱怨。

微软Windows是软件开发的最佳平台。

推理: 微软用优秀而廉价的开发工具,平台和API都有良好的文档记录,平台正在快速发展,这为开发者创造了很多机会,操作系统拥有庞大的用户基础,这对于明显的商业原因很重要,有一个庞大的Windows开发者社区,我还没有因为选择微软而被解雇。

C(或c++)应该是第一种编程语言

第一语言不应该是简单的,它应该是建立学生的思想,为严肃的计算机科学做准备的语言。 C语言是完美的,它迫使学生考虑内存和所有低级别的东西,同时他们可以学习如何构造代码(它有函数!)

c++有一个额外的优势,它真的很糟糕:)这样学生就会明白为什么人们必须想出Java和c#

在编程中使用的进程越多,代码就会变得越糟糕

I have noticed something in my 8 or so years of programming, and it seems ridiculous. It's that the only way to get quality is to employ quality developers, and remove as much process and formality from them as you can. Unit testing, coding standards, code/peer reviews, etc only reduce quality, not increase it. It sounds crazy, because the opposite should be true (more unit testing should lead to better code, great coding standards should lead to more readable code, code reviews should improve the quality of code) but it's not.

我认为这可以归结为我们称之为“软件工程”的事实,而实际上它是设计而不是工程。


以下数字可以证实这一说法:

From the Editor IEEE Software, November/December 2001 Quantifying Soft Factors by Steve McConnell ... Limited Importance of Process Maturity ... In comparing medium-size projects (100,000 lines of code), the one with the worst process will require 1.43 times as much effort as the one with the best process, all other things being equal. In other words, the maximum influence of process maturity on a project’s productivity is 1.43. ... ... What Clark doesn’t emphasize is that for a program of 100,000 lines of code, several human-oriented factors influence productivity more than process does. ... ... The seniority-oriented factors alone (AEXP, LTEX, PEXP) exert an influence of 3.02. The seven personnel-oriented factors collectively (ACAP, AEXP, LTEX, PCAP, PCON, PEXP, and SITE §) exert a staggering influence range of 25.8! This simple fact accounts for much of the reason that non-process-oriented organizations such as Microsoft, Amazon.com, and other entrepreneurial powerhouses can experience industry-leading productivity while seemingly shortchanging process. ... The Bottom Line ... It turns out that trading process sophistication for staff continuity, business domain experience, private offices, and other human-oriented factors is a sound economic tradeoff. Of course, the best organizations achieve high motivation and process sophistication at the same time, and that is the key challenge for any leading software organization.

请阅读文章,了解这些首字母缩写词的解释。