Code Complete: A closer examination (Chapter 1 and 2)
Hello, I am Abiud Orina. I am going to do a 17 part book review of the book Code Complete by Steve Mcconnel.
This review heavily focuses on what I learned from the book with a view of picking out and noting the most important points from the book. This review will also be done in the form of a QA, where I ask a question and answer it. This will better guide my thinking around presenting my ideas on the book. Now, let’s dive right in, shall we?
What is code complete?
Code complete is a book written by Steve McConnel. The book has been highly used since it’s publishing, my software developers around the world. It is considered one of the best practice guidelines for software programming.
Chapter 1: Welcome to software construction
In this chapter, the author discusses the importance of software construction and how it is an important activity in software development.
What is software construction?
Construction is the hands-on part of creating something.
In informal projects, the main activity you think of when you think about creating software is what we call Software Construction. Software construction is not at all mechanical but it involves substantial creativity and judgment
Why is software construction important?
Software construction is important for many reasons but mainly because:
- It is a large part of software development — It takes 30 to 80 percent of the total time taken to develop a project to completion
- It is the central activity in software development. Planning and requirement specification all happen before construction. Testing and integration also happen after construction
- With a focus on construction, the individual programmer’s productivity can improve enormously
Improving construction is thus a way of improving any software development effort. By sharing knowledge of the good practices of software construction, it becomes easier to improve any piece of software out there. The author acknowledges the importance of software construction. However, the author does not elaborate clearly on how it can be used in the software development endeavor.
Chapter 2: Metaphors for a Richer Understanding of Software Development
What is a metaphor?
A metaphor is a way of comparing something you understand poorly to something you understand better.
A good metaphor is simple, relates well to other relevant metaphors, and explains much of the experimental evidence
Metaphors contribute to a greater understanding of software-development issues in the same way that they contribute to a greater understanding of scientific questions
How can we use software metaphors?
A software metaphor is more like a searchlight than a road map. It doesn’t tell you where to find the answer; it tells you how to look for it.
A metaphor is more of a heuristic than an algorithm. It enables you to identify the problem and come up with a solution rather than follow a set of steps to arrive at a solution.
I agree with the author that metaphors can be used in problem-solving to gain insight into programming problems, and imagine better ways of doing things. This is gold for every problem solver out there
What are the common software metaphors?
The author introduces us to a few of the common software metaphors which include Software Penmanship which compares the process of writing a piece of software to the process of writing a letter, Software Farming which envisions the process of creating software for the planting of crops, Software Oyster Farming which teaches the value of creating software by creating small bits at a time, thereby making incremental changes towards the final product, and many more.
I personally like the software farming method to an extent because it easily applies to the daily activities I do as a software developer. However, like any piece of software, it cannot be written like a book since you have to do several iterations on software before coming up with the final product.
How can we combine metaphors?
We can use combinations of metaphors in order to stimulate our heuristic thinking during problem-solving. We often start out a piece of software by writing an idea down somewhere, and then later work on it by proceeding to do proper planning of the problem, and coming up with an amazing solution.
In this chapter, the author introduces us to the importance of metaphors and how they support software development. However, just as with any powerful tool, metaphors can also be destructive. This is a very important point made by the author because if you use the wrong metaphors, the consequences might be catastrophic.
Also, check out my review on chapter 3 and 4