抢单软件开发原理
Rubbish software is produced when we try to do everything at once.
当我们尝试一次做所有事情时,就会产生垃圾软件。
Principles, guidelines, best practices, and rules of thumb — they all make your life easier. Without them, ten-minute tasks can turn into ten-hour tasks.
原则,准则,最佳做法和经验法则-它们都使您的生活更轻松。 没有它们,十分钟的任务可能会变成十小时的任务。
One of the absolute best pieces of advice I received from my mentor very early on in my career was this simple one-liner:
我很早就从我的导师那里得到了绝对最好的建议之一,就是这个简单的单行代码:
“Make it work, make it better, make it faster.”
“使其工作,使其更好,使其更快。”
It’s a slight alteration of Kent Beck’s famous quote, and its simplicity is enabling and puzzling.
这是肯特·贝克 ( Kent Beck)著名语录的略微改动,其简单性令人感到困惑。
“Make it work” is quite easy to wrap your head around. You have a set of requirements, and you’re coding to fulfill them — kid stuff.
“动手做”很容易使您的头脑转转。 您有一组要求,而您正在编写代码来满足它们-孩子们的东西。
“Make it better” is where the meat is. “Better” is the juicy part that you’ll spend the majority of your day achieving. Better code, better design, better approaches. But what does “better” mean? We’ll get around to that later.
“做得更好”是肉的所在。 “更好”是您一天中大部分时间都会实现的多汁部分。 更好的代码,更好的设计,更好的方法。 但是“更好”是什么意思? 我们稍后再解决。
Well, let’s be honest: You often never get around to the “make it faster” aspect of your code — at least not for every part of the software. You want to make your hot paths fast and efficient, but you’re likely in good shape, leaving paths rarely traveled. It’s not worth the effort. Simple as that.
好吧,说实话:您通常永远不会绕过代码的“使其更快”的一面-至少不是针对软件的每个部分。 您想使快速路径高效而高效,但是您