Beauty Is in Simplicity
来源:互联网 发布:kofi2012知乎 编辑:程序博客网 时间:2024/06/16 11:01
Beauty Is in Simplicity
THERE iS ONE qUOTE, from Plato, that I think is particularly good for all software developers to know and keep close to their hearts:
Beauty of style and harmony and grace and good rhythm depends on simplicity.
In one sentence, this sums up the values that we as software developers should
aspire to.
There are a number of things we strive for in our code:
• Readability
• Maintainability
• Speed of development
• The elusive quality of beauty
Plato is telling us that the enabling factor for all of these qualities is simplicity.
What is beautiful code? This is potentially a very subjective question. Per- ception of beauty depends heavily on individual background, just as much of our perception of anything depends on our background. People educated in the arts have a different perception of (or at least approach to) beauty than people educated in the sciences. Arts majors tend to approach beauty in software by comparing software to works of art, while science majors tend to talk about symmetry and the golden ratio, trying to reduce things to formulae. In my experience, simplicity is the foundation of most of the arguments from both sides.
10 97 Things Every Programmer Should Know

Think about source code that you have studied. If you haven’t spent time studying other people’s code, stop reading this right now and find some open source code to study. Seriously! I mean it! Go search the Web for some code in your language of choice, written by some well-known, acknowledged expert.
You’re back? Good. Where were we? Ah, yes…I have found that code that resonates with me, and that I consider beautiful, has a number of properties in common. Chief among these is simplicity. I find that no matter how complex the total application or system is, the individual parts have to be kept simple: simple objects with a single responsibility containing similarly simple, focused methods with descriptive names. Some people think the idea of having short methods of 5–10 lines of code is extreme, and some languages make it very hard to do, but I think that such brevity is a desirable goal nonetheless.
The bottom line is that beautiful code is simple code. Each individual part is kept simple with simple responsibilities and simple relationships with the other parts of the system. This is the way we can keep our systems maintain- able over time, with clean, simple, testable code, ensuring a high speed of development throughout the lifetime of the system.
Beauty is born of and found in simplicity.
- Beauty Is in Simplicity
- Beauty Is in Simplicity
- 简单之美(The Beauty of Simplicity)
- beauty
- beauty
- Beauty
- beauty
- Code Simplicity
- TensorFlow Estimators: Managing Simplicity vs. Flexibility in High-Level Machine Learning Frameworks
- 81. Beauty lies in the lover's eyes. 情人眼里出西施
- Simplicity and Compromise
- Simplicity Comes from Reduction
- Simplicity Comes from Reduction
- PRIMES is in P
- [[][[]]+[]][+[]][++[+[]][+[]]] is "n" in javascript
- Beautiful Architecture: Leading Thinkers Reveal the Hidden Beauty in Software Design
- [转]Beauty
- Beauty everywhere
- 用结构体创建链表和用类创建链表
- 配置opencv1
- Automate Your Coding Standard
- 再论拷贝构造函数和拷贝赋值运算符
- noj算法题——二分查找
- Beauty Is in Simplicity
- opencv模拟button
- 自动排班系统2.0(基于网络流实现的排班系统,附详细注解)
- SHELL基础二函数和字符
- MD5 SHA
- C Primer Plus 第五版 课后练习
- 【Python-Opencv】KNN手写体字符识别
- VS制作程序安装包
- 大型网站系统架构演变之路