How to become a good programmer?
Posted by webstuffscan on December 10th, 2006
I have been programming for over 10 years. Even now I am still learning a lot about good programming. Programming is a skill which is improved by practice and experience. True, people are born with different programming capabilities, still many techniques can be learned only with experience.
What is that distinguishes a good programmer from others? Here is a list from my experience.
1. He thinks - A good coder never jumps straight away into coding when he gets a work. He first *thinks* about the problem and decides on how to approach the solution. He may try out some code snippets and write something which typically thrown out later. But once he starts the actual coding he proceeds at lighting speed.
2. He never duplicates code - A good programmer never, I repeat never duplicates code. To me code duplication is one one of the worst sins for a programmer. In the initial coding some duplication may be there, but an expert removes them gradually.
3. He writes extensible code - Writing extensible code requires considerable experience. This is what makes coding a creative activity. You need to be aware of the full impact of what you are writing in the code’s future life cycle. Design patterns is a collection of techniques which helps in writing extensible code. A good programmer may not know the names of all patterns but he is aware of them nonetheless.
4. He is not afraid to re-factor - No one can write software in a perfect way at the first try. You write a good amount of code, analyze it and then re-factor it. This is a continuous process during coding. I have seen that re-factoring requires considerable amount prior experience.
5. He comments for a purpose - A good programmer comments what is relevant. If he has spend sometime thinking about a portion of code, he will comment his thoughts in the code. This helps another programmer to understand the thoughts and design decisions behind the code he is reading.
Obviously there are other qualities (such as code optimization) which can be seen in a good programmer. But to me the above 5 items are the most important.
Further Reading
What are design patterns
What is refactoring?
- The Subservient Programmer
- My top 10 tips for a successful freelancing career (for programmers)
- Top 10 programmer excuses!
- Top 5 must read books for a programmer
- Top 5 Free Ruby on Rails Tutorials and Books
