diff options
author | Dave Kerr <dwmkerr@gmail.com> | 2019-06-17 14:59:05 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-17 14:59:05 +0800 |
commit | 4bad499d0737a379d687256e1666586b9d8bde92 (patch) | |
tree | 29d1a1c8cda8691461d4e5c6a336c5472428ebaa | |
parent | 472a35170807ae4255cdc687ee1d61e27ed6d2a2 (diff) | |
parent | 46bfe090aae12127a5c77d0594d99963043c2597 (diff) |
Merge pull request #99 from itallmakesense/feature/premature-optimization-effect
Premature Optimization
-rw-r--r-- | README.md | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -23,6 +23,7 @@ Laws, Theories, Principles and Patterns that developers will find useful. * [Hyrum's Law (The Law of Implicit Interfaces)](#hyrums-law-the-law-of-implicit-interfaces) * [Moore's Law](#moores-law) * [Parkinson's Law](#parkinsons-law) + * [Premature Optimization Effect](#premature-optimization-effect) * [Putt's Law](#putts-law) * [The Law of Conservation of Complexity (Tesler's Law)](#the-law-of-conservation-of-complexity-teslers-law) * [The Law of Leaky Abstractions](#the-law-of-leaky-abstractions) @@ -200,6 +201,18 @@ See also: - [Hofstadter's Law](#hofstadters-law) +### Premature Optimization Effect + +[Source](http://wiki.c2.com/?PrematureOptimization) + +> Premature optimization is the root of all evil. +> +> Donald Knuth + +In Donald Knuth's paper [Structured Programming With Go To Statements](http://wiki.c2.com/?StructuredProgrammingWithGoToStatements), he wrote: "Programmers waste enormous amounts of time thinking about, or worrying about, the speed of noncritical parts of their programs, and these attempts at efficiency actually have a strong negative impact when debugging and maintenance are considered. We should forget about small efficiencies, say about 97% of the time: **premature optimization is the root of all evil**. Yet we should not pass up our opportunities in that critical 3%." + +However, _Premature Optimization_ can be defined (in less loaded terms) as optimizing before we know that we need to. + ### Putt's Law [Putt's Law on Wikipedia](https://en.wikipedia.org/wiki/Putt%27s_Law_and_the_Successful_Technocrat) |