我正在对初级(也许是高级)软件工程师所犯的常见错误和错误假设进行一些研究。

你坚持时间最长、最终被纠正的假设是什么?

例如,我误解了整数的大小不是标准的,而是取决于语言和目标。说起来有点尴尬,但事实就是这样。

坦率地说;你有什么坚定的信念?你大概坚持了多长时间?它可以是关于一种算法、一种语言、一个编程概念、测试,或者任何关于编程、编程语言或计算机科学的东西。


当前回答

我喜欢编程。通过研究SICP的书,我发现我一无所知。至少现在我更深入地研究编程了。

其他回答

XML将是一种真正可互操作的、人类可读的数据格式。

我曾经认为我永远不会像微软开发人员那样编程,但现在我认为我可以写同样干净的代码,甚至更好。

@Kyralessa: It's worth noting that on most processors, in assembly/machine language, it's possible for functions to return someplace other than their caller while leaving the stack in good condition. Indeed, there are a variety of situations where this can be useful. One variation I first saw on the 6502, though it works even better on the Z80, was a print-message routine where the text to be printed immediately followed the call instruction; execution would resume after the zero terminator (or, as a slight optimization when using the Z80, at the zero terminator, since letting the zero byte be executed as a NOP would be cheaper than trying to avoid it).

有趣的是,在许多现代语言中,函数都有一个正常的退出点(将在调用之后恢复执行),但也可以通过抛出异常退出。即使在C语言中,也可以使用setjmp/longjmp来模拟这种行为。

这真的很尴尬,但当我开始学习如何编程时,没有什么能让我满意。我想写电子游戏。而不是这些书里让我写的那些琐碎的小程序。所以我决定跳过10章,忽略基础知识。

所以我基本上忽略了变量!

问题是我没有从惯例中识别关键字:

Car car = new Car(); //good
Car test = new Car(); //wrong must be lowercase car!

for (int i = 0; i < 10; i++) //good
for (int test = 0; test < 10; test++)//wrong must be i

我这样做了一年多,甚至用3000行字做了一个井字游戏! 当时我为自己的厉害而激动不已,直到我在互联网上找到了150行一字棋。然后意识到自己是个白痴,就重新开始。

现在流行的$符号作为java/javascript标识符的一部分是非法的。