2 Basic Principles of Software engineering

There are many principles of software engineering. But I just want to share you view of them. the 2 basic principle of software engineering.
- YAGNI ( You aren’t gonna need it)
Always implement things when you actually need them, never when you just foresee that you need them.
Don’t create a code or feature that you don’t need right now. Even if you’re totally, totally, totally sure that you’ll need a feature later on, don’t implement it now.
There are two main reasons to practise YAGNI
- You save time, because you avoid writing code that you turn out not to need.
- Your code is better, because you avoid polluting it with ‘guesses’ that turn out to be more or less wrong but stick around anyway.
2. DRY (Don’t repeat yourself)
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system
One of the best things about code is how reusable it is. Spreading the same logic all over your code undermines readability and makes it difficult for changes. It’s one of the most fundamental principle to building simpler, more maintainable applications.