注重代碼效率
by Harshdeep S Jawanda
通過Harshdeep S Jawanda
如何提升質量:注重態度 (How to skyrocket quality: focus on attitude)
When it comes to discussing quality and how we can improve, the most common things that come to peoples minds are tests, processes, procedures, QA departments, and so on. But they leave out the most important, basic thing, the pre-requisite for achieving high quality: the right attitude. Quality is all about having the right attitude. That’s the starting point.
在討論質量以及我們如何提高質量時,人們最常想到的是測試,流程,程序,質量保證部門等。 但是他們忽略了最重要,最基本的東西,即達到高質量的前提: 正確的態度 。 質量就是擁有正確的態度。 那是起點。
Sure, you need all the other things mentioned above — tests, processes, and procedures — to achieve and maintain a high quality standard. But if you and/or your people don’t have the right attitude, all of the aforementioned things can just become a bullet list on a presentation slide. People can go through the motions of running the relevant tests and following the prescribed processes, but without the right attitude it all becomes a farce of ticking off checkboxes. ?
當然,您需要上面提到的所有其他內容(測試,過程和規程)才能達到并保持高質量的標準。 但是,如果您和/或您的員工態度不正確,上述所有內容都可能會成為演示幻燈片上的項目符號列表。 人們可以進行運行相關測試并遵循規定流程的動作,但是如果沒有正確的態度 ,一切都會成為勾選復選框的鬧劇。 ?
追求完美 (Pursuing perfection)
When it comes to the pursuit of perfection, I’ve always had the belief that:
在追求完美時,我一直堅信:
That’s my mantra and I swear by it. So much so, that I even have it as part of my Twitter profile. ?
那是我的口頭禪 ,我發誓。 如此之多,以至于我什至將它作為我的Twitter個人資料的一部分。 ?
The first part simply means that no matter what you may think, nothing is ever really, truly perfect. If you think something is perfect, wait for five minutes, or two days, or two weeks, and you’ll start to see the small imperfections.
第一部分只是意味著,無論您怎么想,都沒有什么是真的,真正的完美。 如果您認為某事是完美的,請等待五分鐘或兩天或兩周,然后您會開始看到一些小的缺陷。
However, this does not mean that you should lose hope or become disheartened. Just because your thing (product, process, art, whatever) is not perfect doesn’t mean that it can’t be improved upon. This is where the second part comes in: by pursuing perfection you can move closer towards achieving perfection. And eventually, you’ll progress to such a state that you’ll surprise yourself by the progress made.
但是,這并不意味著您應該失去希望或灰心。 僅僅因為您的東西 (產品,過程,藝術品等)不完美,并不意味著就不能對其進行改進。 這是第二部分的目的:通過追求完美,您可以進一步接近實現完美。 最終,您將進步到這樣一種狀態,即您會對所取得的進步感到驚訝。
Psst. It still won’t be perfect, so what?
Psst。 它仍然不是完美的 ,那又如何呢?
This line of thinking has grown out of my background as a computer engineer/scientist. With every passing day, I find many more examples that make me think that it is generally applicable. Unless you can disprove this mathematically, I am going to claim that my mantra is universally true. ?
這種思路已經超出了我作為計算機工程師/科學家的背景。 隨著時間的流逝,我發現更多的例子使我認為它普遍適用。 除非您能從數學上證明這一點,否則我將宣稱我的口頭禪是普遍正確的。 ?
This mantra is the basis for developing the right attitude, achieving high quality, and continuing to improve upon it. Never be satisfied with the quality you have, always be trying to improve.
這種口頭禪是發展正確態度,實現高質量并持續改進的基礎。 永遠不要對自己的質量感到滿意,而要不斷努力。
要進步,要悲觀 (To improve, be pessimistic)
Strange as it may sound, I find this an invaluable attitude to have towards the quality of whatever it is that you are doing.
聽起來可能有些奇怪,但我發現這是一種無價的態度,對您所做的任何事情都具有質量。
Assume that whatever you have made is not going to work, or that it is of low quality. Be pessimistic about the quality of your work.
假設您所做的一切都不起作用,或者質量低劣。 對工作質量感到悲觀。
Then — systematically — prove your pessimism wrong!
然后-系統地證明您的悲觀主義是錯誤的 !
Yeah, that’s right (can’t help but picture David Puddy). ?
是的,沒錯(不禁為David Puddy拍照)。 ?
You may think of this as a roundabout way of doing things, but it works! It ensures that in working to overcome your pessimism (even if it’s a manufactured one) you’re actually improving/ensuring quality.
您可能會認為這是一種繞行的處理方式,但它確實有效! 它可以確保在克服悲觀情緒(即使是制造過的悲觀情緒)的過程中,您實際上正在改善/確保質量。
For a developer, this means writing tests to prove that the code actually works. For an author, this could take the form of soliciting feedback from an experienced editor. Tailor the prove-your-pessimism-wrong step to your particular situation, but do it.
對于開發人員而言,這意味著編寫測試以證明代碼確實有效。 對于作者而言,這可以采取征求經驗豐富的編輯反饋的形式。 為您的特定情況量身定制證明您悲觀的錯誤步驟,但是要這樣做。
All too often, I have seen (and occasionally been a victim of it myself) people suffering due to overconfidence in their work. “It’s just a one-line code change, not even going to create a ripple in the pond”!
我經常看到人們因對工作的過度自信而遭受苦難(有時自己也是受害者)。 “這只是單行代碼更改,甚至不會在池塘中造成漣漪”!
Wrong! Unless you have regression-tested and proven that everything still works, assume that even your tiny change is going to wreak havoc on the larger system. Be pessimistic!
錯誤! 除非您經過回歸測試并證明一切仍然有效,否則請假設即使您的微小更改也將對更大的系統造成嚴重破壞。 悲觀!
反饋是金色的 (Feedback is golden)
This may come as a surprise to many, but you get feedback from only 4% of dissatisfied customers! Putting it another way, for every customer that bothers to complain, 26 others are quietly unhappy and at high risk of leaving without giving you the chance to improve. As you can imagine, unless you listen very carefully to what little feedback you get and take heed, you run a very high risk of living in a fool’s paradise.
這可能會讓許多人感到意外,但您只會從4% 的不滿意客戶那里獲得反饋 ! 換句話說,對于每個煩惱的客戶, 其他26個客戶都非常不高興,并且極有可能在沒有給您改善機會的情況下離開。 可以想像,除非您非常仔細地聽取所獲得的反饋并注意,否則您將有很高的生活在傻瓜天堂中的風險。
That’s why customer feedback is pure gold. I can’t stress enough that you’ve got to really listen to it!
這就是為什么客戶反饋是純金的原因。 我無法承受的壓力是您必須真正聆聽它!
傾聽并內化,即使很痛 (Listen and internalize, even if it hurts)
As a creator, it may hurt to listen to people criticize one of your creations. But think of it as invaluable feedback (we know how important that is ?). The feedback may come from a customer, or it may come from within your organization. Either way, it’s an opportunity to learn, improve, and grow.
作為創作者,聽別人批評您的作品之一可能會很痛苦。 但是,將其視為寶貴的反饋(我們知道這很重要嗎?)。 反饋可能來自客戶,也可能來自組織內部。 無論哪種方式,這都是一個學習,改進和成長的機會。
Creators who take umbrage at feedback and become defensive and non-receptive will never be able to achieve the highest quality standards. These are the people who will either:
虛心于反饋的創作者將變得防御和不接受,將永遠無法達到最高的質量標準。 這些人將要么:
- start looking for excuses as to why the failure happened (with the basic theme being “It wasn’t me”), or 開始尋找失敗原因的借口(基本主題是“不是我”),或者
- become non-receptive and internally keep insisting there’s nothing to improve and that nothing could have been done any better. 變得不容易接受,并且在內部不斷堅持,沒有什么可以改善的,沒有什么可以做得更好的。
These are the sorts of people who will not deliver good quality and will continue to fall further behind their peers in terms of expertise and skill.
這些人不會提供高質量的產品,并且在專業知識和技能方面將繼續落后于同齡人。
硬幣的反面 (The flip side of the coin)
On the other hand (you knew this was coming, right? ?), don’t let a single-minded focus on quality give you tunnel vision and make you blind to everything else.
另一方面(您知道即將到來,對嗎??),不要一味專注于質量給您帶來視野,并使您對其他所有事物都視而不見。
務實 (Be Practical)
One has to balance the need and desire for quality against other factors like cost and time.
人們必須在對質量的需求和期望與其他因素(例如成本和時間)之間取得平衡。
As an example, let’s say your company already has an electrical switch that can take a million on/off operations without failing. You want to improve this switch so that it can handle 10 million operations. But the development, usage of newer and more expensive materials, and testing combined will take an additional two years, with the resultant switch costing 3x that of the million-operation switch. Considering all that, is that quality improvement still worth it?
舉例來說,假設您的公司已經有一個電氣開關,可以完成一百萬次開/關操作而不會失敗。 您需要改進此開關,使其可以處理1000萬次操作。 但是,開發,使用更新和更昂貴的材料以及將測試組合在一起將花費額外的兩年時間,其最終成本為百萬操作開關的三倍。 考慮所有這些,質量改進仍然值得嗎?
In most cases, the answer would be a resounding “no”. Maybe your time will be better spent developing a version that is water-resistant, making it more suitable for outside use, and opening up your product to a whole new market.
在大多數情況下,答案將是響亮的“否” 。 也許您會花費更多的時間來開發一種防水的版本,使其更適合在外部使用,并向全新的市場開放您的產品。
當心異常值 (Beware of the outliers)
The “listen to your customer feedback” advice also comes with a caveat: “Beware of the outliers”. These are the people who will never be satisfied, will always be complaining, and will make you run around trying to satisfy their every whim. Such customers will increasingly start complaining about super-specific scenarios (things that affect a very small percentage of users) or about things that are very subjective (specific to personal taste).
“聽客戶反饋”建議還帶有警告:“當心異常值”。 這些人永遠不會滿足,總是會抱怨,會讓您四處奔波,盡力滿足他們的每一個異想天開。 這樣的客戶將越來越多地開始抱怨超級特定的場景(影響很小比例的用戶的事物)或非常主觀的事物(特定于個人品味)。
If you try to satisfy these outliers, you might end up spending time on features (for example, adding “skins” to your software) that do not have universal appeal. In the process, you’ll take resources away from developing the product in directions that will give the greatest benefit to the greatest number of people.
如果您試圖滿足這些離群值,那么您可能最終會花時間在沒有普遍吸引力的功能上(例如,在軟件中添加“皮膚”)。 在此過程中,您將在開發產品時剝奪資源,而這些開發方向將使最多的人受益最大。
In the end, this often comes down to a judgement call about when to de-prioritize a customer’s feedback. There’s no sure-shot formula to get it right every time.
最后,這通常歸結為關于何時降低客戶反饋的優先級的判斷電話。 沒有確定的公式可以每次都正確。
結論 (Conclusion)
Adjust your attitude to enable you to pursue perfection relentlessly, with eyes on practicality and ears receptive to feedback.
調整自己的態度,使您能夠不懈地追求完美,同時注重實用性和接受反饋的耳朵。
If you found this article helpful, please don’t forget to clap! ?
如果您發現這篇文章對您有所幫助,請別忘了鼓掌! ?
In keeping with with spirit of this article, constructive discussions and corrections are most welcome!
按照本文的精神,非常歡迎進行建設性的討論和更正!
翻譯自: https://www.freecodecamp.org/news/how-to-skyrocket-quality-focus-on-attitude-bd5fadc4dc7f/
注重代碼效率