4 Write Clean and Simple Code

Clean code is code that’s easy to read, understand, and change. It is minimal and concise, as long as those attributes do not interfere with readability. While writing clean code is more an art than a science, the software engineering industry has agreed on multiple principles that, if followed, will help you write cleaner code. In this chapter, you’ll learn 17 principles for how to write clean code that will significantly improve your productivity and combat the problem of complexity.

You may wonder about the difference between clean and simple code. These two concepts are closely interrelated because clean ...

Get The Art of Clean Code now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.