Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between principles YAGNI and KISS?

Obviously there are syntactical differences between YAGNI and KISS but I can't see any semantic differences between them. Are they really in essence just the same thing?

like image 314
Mr Grok Avatar asked Sep 23 '14 16:09

Mr Grok


People also ask

What is KISS AND DRY principle?

May 31, 2022. Keep it simple, stupid (KISS), you aren't gonna need it (YAGNI), and don't repeat yourself (DRY) are some of the most powerful digital product design principles. They lay the foundations for best practices that developers use to build better products every day.

What does the YAGNI principle suggest?

YAGNI principle ("You Aren't Gonna Need It") is a practice in software development which states that features should only be added when required. As a part of the extreme programming (XP) philosophy, YAGNI trims away excess and inefficiency in development to facilitate the desired increased frequency of releases.

What is KISS principle in coding?

What is Keep It Simple, Stupid (KISS)? Keep it simple, stupid (KISS) is a design principle which states that designs and/or systems should be as simple as possible. Wherever possible, complexity should be avoided in a system—as simplicity guarantees the greatest levels of user acceptance and interaction.

How do you achieve DRY principle?

Don't Repeat Yourself (DRY) The DRY principle is stated as "Every piece of knowledge must have a single, unambiguous, authoritative representation within a system". The way to achieve DRY is by creating functions and classes to make sure that any logic should be written in only one place.


1 Answers

YAGNI (You aint gona need it) refers to over analyzing and implementing things that may or may not be needed. Sure algorithmic elegance is nice and all but most situation you dont need it. In general engineering terms you should be carefull not to include your own requirements so that you dont taint your customer needs with your own ideas that end up costing the project with little impact for the client.

KISS (Keep it simple stupid) refers to the fact that easy systems are easier to manage. Keeping things simple is not nesseserily less work (like YAGNI is) since it requires more knowlege to implement. They are sometimes similar but grow from different needs.

YAGNI grows from a too much future anticipation, overzealous workers if you may. KISS is a strategy that tries to counteract human tendency for design creep.

like image 174
joojaa Avatar answered Oct 05 '22 17:10

joojaa