Simplest Implementation – The Daily WTF

Date:

Share:

As the saying goes, there are only two hard problems in computer science: naming things, cache invalidations, and off by one errors. Chris‘s predecessor decided to tackle the second one, mostly by accurately(?) naming a class:

class SimpleCache
{
}

This is, in fact, the simplest cache class I can imagine. Arguably, it’s a bit too simple.

Instances of this class abound in code, though no one is entirely sure why. Future optimization? Just no one understanding what they’re doing? Oh right, it’s that one. It’s always no one understanding what they’re doing.

[Advertisement]
Keep all your packages and Docker containers in one place, scan for vulnerabilities, and control who can access different feeds. ProGet installs in minutes and has a powerful free version with a lot of great features that you can upgrade when ready.Learn more.

Source link

Subscribe to our magazine

━ more like this

Shek O Bus Terminus in Hong Kong

After the journey through the winding roads of Hong Kong Island's verdant south side, the first sight that greets visitors to the popular beach...

The Music Biopic is a Genre That Will Never Fully Work

How Springsteen Tried to Do Something DifferentThere has been an increasing demand for music biopics following the success of Bohemian Rhapsody in 2018. That...

The Best Outfits From “Love Island USA” Season 7 Reunion

While each product featured is independently selected by our editors, we may include paid promotion. If you buy something through our links, we may...

Clockwise #618: A Polyamorous Situationship

Support this show Enjoy Clockwise Unwound: Ad-free episodes and an extra Overtime topic every week. #618: A Polyamorous Situationship August 13th, 2025 · 29 minutes Our display setup and window...