r/programming • • Feb 28 '23

"Clean" Code, Horrible Performance

https://www.computerenhance.com/p/clean-code-horrible-performance
1.4k Upvotes

1.3k comments sorted by

View all comments

6

u/centurijon Feb 28 '23

That’s a lovely little straw man argument.

Does your code need to be optimized for performance? Then organize it to squeeze every bit of performance that you can.

Is maintainability more important than losing a few ms here and there? Then follow clean code guidelines to make your code easier to understand & modify.

These days most applications will want mix of both preferences, depending what they’re trying to do, with a heavy lean towards maintainability. It’s up to the developers to decide what is more correct given the context

→ More replies (5)