Today there was an interesting discussion between Kent Beck, Martin Fowler, and David Heinemeier Hansson on the nature and use of Test-Driven Development (TDD), where one writes tests first and then writes code. Each participant in the conversation had different personal preferences for how they write code, which makes sense. However, from each participant’s personal preference you could extract an identical principle: “I need to observe something before I can make a decision.” Kent oft...| Code Simplicity
One thing we know about software design is that the future is important. However, we also know that the future is very hard to predict. I think that I have come up with a way to explain exactly how hard it is to predict the future of software. The most basic version of this theory is: The accuracy of future predictions decreases relative to the complexity of the system and the distance into the future you are trying to predict. As your system becomes more and more complex, you can predict sma...| Code Simplicity
What if every software developer could gain the knowledge of long experience without having to go through the pain of repeated failure? What if, instead of being a continuous chaos of complexity and argument, the process of software development could be a sane, orderly progression that was well-understood by every single programmer involved? What if all programmers and their managers shared a common ground for discussing software development decisions–a common ground that was based on facts...| Code Simplicity
Many people think that the readability of code has to do with the letters and symbols used. They believe it is the adding, removing, or changing of those symbols that makes code more readable. In some sense, they’re right. However, the underlying principle is: Readability of code depends primarily on how space is occupied by letters and symbols. What does that mean? Well, it means two things: Code should have the proper amount of white space around it. Not too much, not too little. There sh...| Code Simplicity
In the context of The Equation of Software Design, it is now possible to reduce the primary principles of software design into just two statements: It is more important to reduce the Effort of Maintenance than it is to reduce the Effort of Implementation. The Effort of Maintenance is proportional to the complexity of the system. And that is pretty much it. If all you knew about software design were those two principles and the purpose of software, you could evolve every other general principl...| Code Simplicity
So today I was playing around with a little equation that may in fact explain nearly all of the principles of software design. I don’t know that it’s actually mathematically solvable in terms of numbers, but it does demonstrate the factors present in software development decisions and how they relate to each other. Before I go into the equation, though, I have to define the factors that are present when a designer is deciding whether or not to implement something, or how to implement it: ...| Code Simplicity