You should name a variable using the same care with which you name a first-born child.
Of course bad code can be cleaned up. But it’s very expensive.
It is not the language that makes programs appear simple. It is the programmer that makes the language appear simple!
When you are working on a problem, you sometimes get so close to it that you can’t see all the options. You miss elegant solutions because the creative part of your mind is suppressed by the intensity of your focus. Sometimes the best way to solve a problem is to go home, eat dinner, watch TV, go to bed, and then wake up the next morning and take a shower.
Why do most developers fear to make continuous changes to their code? They are afraid they’ll break it! Why are they afraid they’ll break it? Because they don’t have tests.
You are reading this book for two reasons. First, you are a programmer. Second, you want to be a better programmer. Good. We need better programmers.
Clean code always looks like it was written by someone who cares.
The problem is that we view estimates in different ways. Business likes to view estimates as commitments. Developers like to view estimates as guesses. The difference is profound.
Programming is a social activity.
Perhaps you thought that “getting it working” was the first order of business for a professional developer. I hope by now, however, that this book has disabused you of that idea. The functionality that you create today has a good chance of changing in the next release, but the readability of your code will have a profound effect on all the changes that will ever be made.
I’m a programmer. I like programming. And the best way I’ve found to have a positive impact on code is to write it.
The only way to go fast, is to go well.
Programmers must avoid leaving false clues that obscure the meaning of code.
Good architecture makes the system easy to understand, easy to develop, easy to maintain, and easy to deploy. The ultimate goal is to minimize the lifetime cost of the system and to maximize programmer productivity.
Don’t Use a Comment When You Can Use a Function or a Variable.
Abstraction is the elimination of the irrelevant and the amplification of the essential.
Any organisation that designs a system will produce a design whose structure is a copy of the organisation’s communication structure.
Dijkstra once said, “Testing shows the presence, not the absence, of bugs.” In other words, a program can be proven incorrect by a test, but it cannot be proven correct. All that tests can do, after sufficient testing effort, is allow us to deem a program to be correct enough for our purposes.
QA and Development should be working together to ensure the quality of the system. The.
You see, programmers tend to be arrogant, self-absorbed introverts. We didn’t get into this business because we like people.