Key principles in software development
08 Oct 2017The great things survive despite of time, so do key software principles.
In development process, these principles give the instructions to build a high-quality product in a limited time by using resources efficiently. Both individuals and big-size teams can apply them.
DRY - Don’t Repeat yourself
Every small pieces of knowledge may only occur exactly once in your entire system.
A small piece of knowledge must have a single, unambiguous, authoritative representation within a system.
Keep the followings in mind to achieve DRYness.
- Planning: DRY and modular architecture require good planning.
- Refactoring: When you find yourself writing code that is similar or equal to something you have written before, take a moment to think about what you are doing and don’t repeat yourself.
KISS - Keep It Simple stupid
It is not just applied to software world. It is all about simplicity.
In software development, there are many people involved in the conceptual process, who do not have the technical expertise to make a reliable cost-benefit analysis. Hence, they don’t see the problem. Double-check the requirements whether they are really stripped down to the essence that the client needs. Take the time to discuss critical points and explain why other solutions might be more suitable.
Finally, try to think out-of-the box if a task looks complicated to you. If someone is explaining to you his requirements, and you are thinking that it’ll be tough and complex to implement, you are right under almost any circumstances.
YAGNI - You Aren’t Gonna Need it
If it is not in the concept, it is not in the core.
YAGNI asks you to reduce the number of components.
DRY vs KISS vs YAGNI
All of them strives for a simple solution and reduces complexity by different approaches.
- DRY divides a project into manageable components.
- KISS tries to implement something as easily as possible.
- YAGNI forces to not implement any unnecessary things.
It is a short sum-up version of the comprehensive article written by Chris Peters.