The Clean Coder, Chapter 5 & 6

In chapter 5 and 6 of The Clean Coder, author Robert Martin explains two very important habits of a professional and successful programmer i.e. testing code following Test Driven Development (TDD) and practicing your craft. In chapter 5, Martin goes into detail on how he was introduced to TDD and what are the key benefits of TDD. In chapter 6, Martin explains the most important ingredient that I believe is necessary for any field in order to be successful in that field, practicing. Practicing is an exercise that can keep programmer’s skills sharp and can eventually result in perfection with great confidence and accuracy.

There were few great points that the author mentioned about TDD. First point that TDD is a three step-by-step testing process which assures that the new code added did not break the preexisting working code. Second point was that TDD gives programmers courage. If a programmer believes in his tests and is confident about his tests, then this trust eliminates any fear from making changes to his/her or someone else’s code. I believe all the benefits of TDD can be summarize in this one quote, “It is a discipline that enhances certainty, courage, defect reduction, documentation, and design.” TDD does give programmers to test their code on time and helps them break down problem into small pieces which enhances their problem solving skills. A single practice that makes TDD different and interesting from other testing practices is that in TDD programmers have to write their tests before their production code. I have learned about TDD in my Software Construction and Software Quality Assurance courses, and from my personal experience as a beginner, it is a little weird. But after reading this author’s take on TDD, I understand that it will be very helpful in the long run. In other words, I did not had enough practice with TDD which made me a little uncomfortable.

About any field out there, if people do not practice and keep their skills up-to-date and sharp, their demand in the market will degrade dramatically over time. One major point that the author mentioned was that it is not the employers who should be allowing employees to practice. It is employee’s responsibility to keep their skills sharp. I strongly agree with this point because practicing should be fun and exciting. It should be done outside work and on your own time. I believe practicing is very crucial to any field, but for programmers it should be a natural thing because without practice we tend to freeze in time and previously learn knowledge tends to escape from our mind. More practice gives you an automated and instinctive ability where your body and fingers react with your mind directly, without thinking, with perfection. As the author suggests, “We choose a repertoire of problem/solution in pair and execute them over and over again until we know them cold.” For me, lesson learn is that practice a problem over and over again until I know it cold.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s