principles:keep_it_simple_stupid
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| principles:keep_it_simple_stupid [2025-11-04 22:52] – created luciennej68 | principles:keep_it_simple_stupid [2025-11-25 10:53] (current) – old revision restored (2021-10-20 21:09) christian | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | Waiting times can be reduced when the number of staff could be increased for busier time periods. Perhaps weekends won' because the busiest time of the week, and summer time won't end up being busiest year. | + | ====== Keep It Simple Stupid (KISS) ====== |
| - | When you look at today' | + | ===== Variations |
| - | Doctors are breaking even with Medicare patients and cannot survive these people do not have access to enough regular insurance people. Many are planning on quitting the profession if for example the new 新潟市中央区 肩こり plan is implemented this is because cannot are in business with its regulations. Is going to also mean a lack of doctors | + | * (Rule of) Simplicity |
| + | * KISS may also mean "Keep it short and simple" | ||
| - | They monitor the performance of a hospital | + | **Remarks**: |
| - | Of course, the issue with this is pretty obvious. With a discount healthcare plan, you've to pay for your expenses out-of-pocket. On the upside, means positivity . do pay, the bill will be extremely incredibly low. Some people receive discounts of 50 percent or more with these kinds of plans. If you go to your doctor examination actually year, this is simply not a bad deal. A visit that costs $200 may discounted to $100, for the way generous the program was. True, you don't have insurance, however, you were still able in order to $100. Should you have had nothing available, you wouldn' | ||
| - | You ought to look to the news related to the industry. You will also where possible find the actual companies will be hiring the healthcare contractors. If you need it in acquiring a transfer from one industry to your 新潟市中央区 肩こり you'll be able to must first of all find out the qualities which is fruitful for your health companies. | + | ===== Context ===== |
| - | Acupuncture for back pain can be very very effective. After the first treatment he reported that discomfort was more pleasant and that he can sit a little longer. Since any Acupuncture clinic will likely ask anyone to do numerous visits we got him again and found that he nonetheless feeling just better. After three visits his pain was reduced greatly and his golf game was back again again. After five visits he can sit for a extended period of time than he has in a few months. The real story here is always that the man is in his late seventies! | + | * [[contexts: |
| + | * [[contexts: | ||
| + | * [[contexts: | ||
| + | * [[contexts: | ||
| - | Big government has won and free market has lost on this one. But honestly, totally free whataburger coupons market folks did not care or give one thought towards the uninsured. I really believe a free market is key for a remarkable growing economy, but once we let people starve typically the streets, it isn't worth getting this done. | + | ===== Principle Statement ===== |
| - | All [[http:// | + | A simple solution |
| - | As far as pick up lines are concerned, I do think I took care in the worst culprits. And as for dating tips for men, We are back with additional of those involved with the subsequent. In the meantime, I'd love a guy's watch. What are your flirting " | ||
| - | You choose to go the Acupuncture clinic lot of coaching as well as tutoring. It is very important to begin your career with a normal healthcare professional. Some of the pros begin their career as health aides. They usually look at the homes. | + | ===== Description ===== |
| - | Income Security outlays elevated from 2001 to 2010 by 306%. The dollar value from the increase | + | The KISS principle |
| - | I have gotten | + | A solution that follows the KISS principle might look boring or even " |
| + | |||
| + | This does not mean that features like inheritance and polymorphism should not be used at all. Rather they should only be used when they are necessary or there is some substantial advantage. | ||
| + | |||
| + | ===== Rationale ===== | ||
| + | |||
| + | A simpler solution is better than a complex one because simple solutions are easier to maintain. This includes increased readability, | ||
| + | |||
| + | The advantage of simplicity is even more significant when the person who maintains the software is not the one who once wrote it. The maintainer might also be less familiar with sophisticated programming language features. So simple and stupid programs are easier to maintain because the maintainer needs less time to understand them and is less likely to introduce further defects. | ||
| + | |||
| + | One reason to create more complex code is to make it more flexible to accommodate further requirements. But one cannot know how to make it flexible or if that flexibility will be ever needed. | ||
| + | |||
| + | "When you make your code more flexible or sophisticated than it needs to be, you over-engineer it. Some do this because they believe they know their system' | ||
| + | |||
| + | Another reason to create more complex code is to make optimizations. An optimized code is a more complex code. Pareto principle applies also in code: a program | ||
| + | "Three rules of optimization": | ||
| + | |||
| + | |||
| + | ===== Strategies ===== | ||
| + | |||
| + | This is a very general principle, so there is a large variety of possible strategies to adhere more to this principle largely depending on the given design problem: | ||
| + | |||
| + | * Avoid inheritance, | ||
| + | * Avoid low-level optimization of algorithms, especially when involving Assembler, bit-operations, | ||
| + | * Use simple brute-force solutions instead of complicated algorithms. Slower algorithms will work in the first place. | ||
| + | * Avoid numerous classes and methods as well as large code blocks (see [[More Is More Complex]]) | ||
| + | * For slightly unrelated but rather small pieces of functionality use private methods instead of an additional class. | ||
| + | * Avoid general solutions needing parameterization. A specific solution will suffice. | ||
| + | * ... | ||
| + | |||
| + | |||
| + | ===== Caveats ===== | ||
| + | |||
| + | See section [[#contrary principles]]. | ||
| + | |||
| + | |||
| + | ===== Origin ===== | ||
| + | |||
| + | The principle was coined by the American engineer Kelly Johnson referring to the requirement that a military aircraft should be repairable with a limited set of tools under combat conditions ((Ben R. Rich: // | ||
| + | |||
| + | The principle of striving for simple solutions sometimes is also called "(rule of) simplicity" | ||
| + | |||
| + | |||
| + | ===== Evidence ===== | ||
| + | /* Comment out what is not applicable and explain the rest: */ | ||
| + | /* * [[wiki: | ||
| + | /* * [[wiki: | ||
| + | |||
| + | |||
| + | [[wiki: | ||
| + | |||
| + | [[wiki: | ||
| + | |||
| + | The following hypotheses can be stated: | ||
| + | - Simpler solutions are faster | ||
| + | - Simpler solutions yield fewer implementation faults (which reduces testing effort). | ||
| + | - Simpler solutions are easier to maintain, i.e. detecting and correcting defects is more effective and efficient. | ||
| + | - Simpler solutions yield more reliable software, i.e. fewer defects show up after releasing the software. | ||
| + | |||
| + | All these hypotheses can be examined with respect to different complexity metrics. | ||
| + | |||
| + | Hypothesis 1 is true by definition. If the solution cannot be implemented quickly, it is not simple. | ||
| + | |||
| + | Though hypotheses 2 and 3 are not true by definition but they can be regarded intuitively clear. Nevertheless, | ||
| + | |||
| + | Furthermore, | ||
| + | |||
| + | Lastly, hypothesis 4 is likely to be false. Several studies relating complexity metrics and post-release reliability show that module size in lines of code predicts reliability at least as good as the McCabe metric (also called cyclomatic complexity) ((see Albert Endres, Dieter Rombach: //A Handbook of Software and Systems Engineering//, | ||
| + | |||
| + | |||
| + | ===== Relations to Other Principles ===== | ||
| + | |||
| + | ==== Generalizations ==== | ||
| + | |||
| + | ==== Specializations ==== | ||
| + | |||
| + | * [[More Is More Complex]] (MIMC): KISS states that one should strive for simplicity. MIMC makes this more concrete stating that more of anything (methods, classes, lines of code, ...) increases complexity. | ||
| + | * [[You Ain' | ||
| + | * [[Rule of Parsimony]] | ||
| + | * [[Rule of Robustness]] | ||
| + | |||
| + | ==== Contrary Principles ==== | ||
| + | |||
| + | Note that many principles are contrary to KISS. This means that it is worthwhile | ||
| + | |||
| + | * **[[Generalization Principle]] (GP)**: This is the directly converse principle. A generally applicable solution typically is not simple anymore. | ||
| + | * **[[Murphy' | ||
| + | * [[Model Principle]] (MP): There are often simpler ways to build a software system | ||
| + | |||
| + | ==== Complementary Principles ==== | ||
| + | |||
| + | ==== Principle Collections ==== | ||
| + | |||
| + | {{page> | ||
| + | {{page> | ||
| + | |||
| + | |||
| + | ===== Examples ===== | ||
| + | |||
| + | ==== Example | ||
| + | |||
| + | Simplicity | ||
| + | |||
| + | <code java> | ||
| + | public String weekday1(int dayOfWeek) | ||
| + | { | ||
| + | switch (dayOfWeek) | ||
| + | { | ||
| + | case 1: return " | ||
| + | case 2: return " | ||
| + | case 3: return " | ||
| + | case 4: return " | ||
| + | case 5: return " | ||
| + | case 6: return " | ||
| + | case 7: return " | ||
| + | default: throw new IllegalArgumentException(" | ||
| + | } | ||
| + | } | ||
| + | |||
| + | public String weekday2(int dayOfWeek) | ||
| + | { | ||
| + | if ((dayOfWeek < 1) || (dayOfWeek > 7)) | ||
| + | throw new IllegalArgumentException(" | ||
| + | |||
| + | final String[] weekdays = { | ||
| + | " | ||
| + | |||
| + | return weekdays[dayOfWeek-1]; | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | Both methods do exactly | ||
| + | |||
| + | On the other hand '' | ||
| + | |||
| + | So it's not objectively clear which of the two implementations KISS prefers without saying which complexity metric to apply. But this ambiguity is not a problem since principles are not meant to be unambiguous and objective. Eventually a human developer has to decide which solution to implement and the principles only give guidelines. | ||
| + | ===== Description Status ===== | ||
| + | /* Choose one of the following and comment out the rest: */ | ||
| + | / | ||
| + | [[wiki: | ||
| + | / | ||
| + | |||
| + | ===== Further Reading ===== | ||
| + | |||
| + | * [[wiki> | ||
| + | * [[wp> | ||
| + | * [[http:// | ||
| + | * [[http:// | ||
| + | |||
| + | ===== Discussion ===== | ||
| + | |||
| + | Discuss this wiki article and the principle on the corresponding [[talk: | ||
principles/keep_it_simple_stupid.1762293121.txt.gz · Last modified: by luciennej68
