Get the latest tech news

Write code that is easy to delete, not easy to extend (2016)


“Every line of code is written without reason, maintained out of weakness, and deleted by chance” Jean-Paul Sartre’s Programming in ANSI C. Every line of code written comes at a price: maintenance. To...

Managing how the code fits together, or which parts depend on others, is a significant problem in large scale systems, and it gets harder as your project grows older. This isn’t as uncommon as you might think: One of the most popular and beloved python http clients, requests, is a successful example of providing a simpler interface, powered by a more verbose-to-use library urllib3 underneath. For example, Twitter’s Finagle uses a common API for services, and this allows generic timeout handling, retry mechanisms, and authentication checks to be added effortlessly to client and server code.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Code

Code

Related news:

News photo

Anthropic's AI Can Now Run And Write Code

News photo

Anthropic’s AI can now run and write code

News photo

What docs-as-code means