DEV Community

Discussion on: What's your favorite software idiom/aphorism?

Collapse
 
bytebodger profile image
Adam Nathaniel Davis • Edited

There are only two hard things in computer science: cache invalidation and naming things. - Phil Karlton

I only actually heard this aphorism a few years ago (although the original quote is from far earlier). But it's amazing how often I think of it now. Obtuse, hard-to-follow code can often be "magically" transformed by applying the proper descriptive names to the variables / methods / functions / classes / etc. And yet, it can often be soooooo difficult, when you're writing the code for the first time, to settle on just the "perfect" names that will render the code clear and self-explanatory.