當前位置

首頁 > 英語閱讀 > 雙語新聞 > 開發者應該反問自己的10個問題

開發者應該反問自己的10個問題

推薦人: 來源: 閱讀: 2.46W 次

So you want to become a web developer?

你想成爲一名web開發者嗎?

Well then it’s time to put down that “Learn Super Duper Language v8.3 in 24 hours” book. Instead, make it a habit to ask yourself these 10 questions every day.

那麼,現在是時候放下《24小時學會超級騙子語言v8.3》書,相反,你應當養成每天反問自己以下10個問題的習慣。

Is there a pattern here?

是否有一種模式存在?

開發者應該反問自己的10個問題

Looking for patterns in what works and what doesn’t work leads to discovering the underlying principles that drive seemingly unrelated concepts and behaviours. To get a deeper understanding of the work that you do make it a habit of asking yourself “Is there a pattern here?”.

找尋模式中的可行與不可行將發現其中看似無關的想法或基本原則。要對工作達到深入的理解,你必須養成反問自己“是否有一種模式存在?”的習慣。

This applies to more than just your code. Is there a pattern in the types of changes requested by business? Is there a pattern in the way technologies evolve? Are you seeing the same types of bugs popPing up again and again?

它不僅僅適用於你的代碼。是否有適應各類型商業變化的模式嗎?是否有一種適用於技術發展的模式?你有沒有看到同類型的錯誤如雨後春筍般冒出來?

To understand is to perceive patterns — Isaiah Berlin

理解就是理解模式 -- 以賽亞·伯林

How can I make this simpler?

怎麼讓它變得更簡單?

Often as web developers we want to produce complex and scalable solutions. Making something tremendously complex makes you feel like the master of your universe. The problem is that you will never be able to predict how your product and business is going to change in the future.

開發者經常想得到複雜的和可擴展的解決方案。做一些極爲複雜的東西,覺得自己就是自己宇宙的主宰。問題是將來你永遠無法預知產品和業務會如何改變。

“Architecture” and coding is much more like gardening than architecture. You need to be able to adapt to an ever changing environment. The more complex your solution the more difficult this becomes.

“架構”和代碼更像是園藝而不是建築。你必須要有能力去適應不斷變化的環境。越複雜的解決方案越難做。

Simplicity is the ultimate sophistication. — Leonardo da Vinci

簡潔是終極的複雜 --  列昂納多·達·芬奇

Why does it work like that?

東西爲什麼像那樣運作?

Knowing that something works and knowing why it works that way are two very different things. If you know why something behaves the way it does you are able to make significantly better decisions.

知道東西像那樣運作和知道爲什麼會像那樣運作是兩個完全不同的事。如果你知道事情爲什麼會那樣,那麼你就能夠做出更好的決策。

The difference between a great coder and somebody who knows a programming language is the depth of understanding that comes from understanding why.

一個偉大的程序員和知道有某種編程語言的人來說,差別在於理解爲什麼的深度。

The same principle applies when fixing an issue. “Just restart the service.” “Have you tried rebooting it?” We have all said something along those lines when a problem pops up. Every time you say something like that you lose a golden opportunity to learn.

同樣的原理也適用於問題修正。“重啓一下服務。” “你試過重啓嗎?” 當有問題發生時,我們經常會想到這些話。每次你這樣說時,你就失去了一個學習的黃金機會。

Understanding why something broke allows you to fix the root cause and eliminate this class of issues permanently. At the very least you won’t make the same mistake again.

理解爲什麼出現這樣的錯誤,將修正根本原因,避免出現治標不治本。最起碼,你以後不要再犯同樣的錯誤。

Has somebody done this before?

之前有沒有人做過?

Whenever you find yourself inventing a complex algorithm you are probably on the wrong track. Unless you are busy researching a PHD thesis chances are extremely good that somebody else has already solved this problem.

無論何時,你發現自己發明了一個複雜的算法,你很可能走在了錯誤的軌道上。除非你搜索到一份別人正好解決了這個問題博士論文。

Need to write an algorithm to add a label to the item closest to a users mouse? Have a look at Voronoi Tesselations. Want to find the shortest path for a delivery truck? Look at Dijkstra. Want to find tags similar to the one the user just entered, how about figuring out it’s Levenschtein distance.

需要編寫一個向用戶鼠標旁的item添加標籤的算法?看看Voronoi Tesselations. 想要找到卡車送貨的最短路徑?看看Dijkstra. 想要找到用戶輸入內容的最接近的標記?應該是找到它的Levenschtein distance.

Those are just a few examples but trust me, they are everywhere.

這只是幾個簡單示例,相信我,它們無處不在。

If I have seen further it is by standing on ye sholders of Giants. — Isaac Newton

如果我看得更遠,那是因爲我站在巨人的肩上 -- 艾薩克·牛頓

Who said it first?

誰最先提到它?

So you think you know REST right?

你認爲你知道REST嗎?

Have you read Roy Fielding’s original paper describing REST and do you understand it’s intended purpose? That blog post by that guy who has 5 minutes more experience than you using the REST API generation wizard in Super cool IDE v7 doesn’t count.

你有讀過Roy Fielding描述REST的論文原文嗎?你真的明白它的最初用意嗎?那種在IDE v7工具中比你多用REST API生成嚮導5分鐘的傢伙寫出來的博客可不算數的。

Do yourself a favour and always try read the original source of a concept or theory. Then by all means go read the latest developments by industry thought leaders but if you don’t know where they started how can you follow where they are going?

幫自己一個忙,試圖去讀概念或原理的原始文檔,然後通過各種手段去了解行業領袖的最新發展動態。如果你不知道他們是從哪些開始的,那就緊跟他們的步伐吧?(不知道他們從哪來,就跟着他們到哪去吧!)

Do I love what I’m doing?

我喜歡現在所做的嗎?

Lets face it programming is hard.

請面對編程其實是很難的。

Besides being hard programming is constantly evolving. The state of the art framework from 2 years ago is a clunky dinosaur by todays standards. To stay at the top of your game you will need to commit to a lifelong process of learning and research.

除了很難以外,編程還是發展很快的。Art框架從2年前的“笨重恐龍”已經發展到今天的標準。爲了站到你“遊戲”的頂端,你必須樹立一個終生學習和研究的信念。

If you don’t love what you are doing you don’t have a hope in hell of keeping up with the guys who do. So find out what kind of coding gets you fired up. Don’t decide to become a security specialist because there is a gap in the market or because it pays well, don’t become a UX expert just because an article just came out in WIRED saying that UX is the hottest job in tech.

如果你不喜歡你所做的,那麼你就沒有跟上其他傢伙(喜歡自己所做的)的可能。所以找到讓你激情燃燒的編程類型!不要因爲市場缺口或者收入不菲而決定成爲一名安全專家,不要因爲一篇文章說UX是最熱門的職業而決定成爲一名UX專家。

I’ll say it again, do what you love.

再說一次,做你喜歡的。

Do what you love and the necessary resources will follow. — Peter McWilliams

做你喜歡的,所需的資源將隨之而來的 -- 彼得·麥克威廉斯

Where else could I use this?

其他地方還可以使用嗎?

One of the biggest limits I see web developers placing on themselves is a failure of imagination.

我看到web開發者最大的一個限制就是,自己失敗的想象力。

If we learn something in a specific context or see a technique used to solve a specific problem we assume that’s the only place it applies. This is almost always wrong. Every time you learn something new ask yourself: “Where else could I use this?”.

如果我們學習到一個適應於特定環境的東西,或者看到解決某個特定問題的技術時,我們認爲這就它唯一適用的地方。這是完全錯誤的。每當學到新東西時,反問自己:“其他地方還可以使用嗎?”

Found great new positioning methods to place nodes on a graph, how about applying that same technique to find interesting data points in a dataset that has 2 dimensions? Found a cool way to send data over websockets from the client to the server? How would this apply in making a scalable set of backend services? Sometimes you will be wrong, but sometimes you will be right.

當發現了在圖表上定位節點的新的偉大的方法時,是不是可以將它應用於二維數據集中感興趣數據的定位呢?當發現通過websockets從客戶端發送數據到服務器端的新方法時,它怎麼才能應用到可擴展的後臺服務上呢?有時是錯誤的,但有時也是正確的。

Which brings us to our next question…

這給我們帶來了下一個問題......

Logic will get you from A to Z; imagination will get you everywhere. — Albert Einstein

邏輯只能帶你從A到Z,想像力去可以帶你到任何地方 --- 阿爾伯特·愛因斯坦

What did I fail at today?

今天有什麼做錯的嗎?

One of the easiest ways to increase innovation is to lower the cost of failure.

增加創收的最簡單方法是降低錯誤的損失。

The game developing company Valve has embraced this like few others. The same applies to your progression along the path to becoming a web developer, if you are afraid to fail you will never make those big breakthroughs.

遊戲開發公司Valve和其他幾個公司很認爲這個觀點。這同樣適用你成爲web開發者的進步過程。如果你害怕失敗,你就不會有大的突破。

Be brave, try something, fail, learn and try again.

勇敢、嘗試、失敗、學習然後再來。

Do not fear mistakes. You will know failure. Continue to reach out. — Benjamin Franklin

不要害怕錯誤,認識失敗,然後重新來過。--- 本傑明·富蘭克林

How can we make this possible?

怎麼使它變成可能?

In the world we live in there really is very little that is impossible (with a few exceptions).

我們生活在世界上很小的一個地方是不可能的(除了少數例外)。

Start from the assumption that whatever you want to do is possible and then work your way back. You might find that what you wanted to do is impractical for the time being but with the pace of change in todays world, it might become practical sooner than you think.

假設不管你做的什麼事情都是可行的,然後採用向後的方向回推回去。你可能會發現,你想做的暫時是不切實際的,但它足以改變世界,可能變成現實的速度比你想像的還要快。

It always seems impossible until its done. — Nelson Mandela

直到完成前,似乎都還是不可能的 --- 納爾遜曼德拉

Who can I learn from?

我可以向誰學習?

You should never work anywhere where you are the smartest person in the room.

永遠不要在你是最聰明的地方工作。

Pick jobs and companies where you can work with people who inspire you and challenge you to be better. It doesn’t have to be coding related, there is a world outside your text editor and the command line. Learn things from other fields and find ways to apply it in your job.

挑選擁有可以啓發你、激勵你做得更多的同事的工作和公司。不要與編程扯上關係,在文本編輯器和命令行外面還有一個完整的世界存在。從其他領域學習,設法應用到你的工作中。

Being competent isn’t good enough anymore.

不管怎麼樣,比稱職更好!