Programmers share jokes as much as anyone else. You may even find some of them funny, although more likely your mileage may vary (YMMV), as they say. From the right angle, that even looks like a feature, not a bug.
In the book Small Pieces Loosely Joined, David Weinberger offers an insight that hasn’t become less fresh in the twenty years since the book’s publication:
In fact, you can look at the Web as consisting of two basic forms of knowledge: the database and the joke. […] Unlike databases, jokes, the other form of knowledge on the web, reveal what you weren’t expecting. If they’re predictable, they’re about is funny as a database. […] Jokes are all about context.
Weinberger explains that you can learn a lot about someone’s cultural context by what they find funny. The same thing works in niche fields: the ability to appreciate a field’s in jokes depends on domain knowledge or shared professional experience. Programming jokes work when you know enough to get them. And programming culture, more than many others, exists online.
The Prolog lightbulb joke
I once read a Prolog programming language tutorial whose introduction promised it would teach ‘enough Prolog to understand The Prolog Lightbulb Joke’.
How many Prolog programmers does it take to change a lightbulb?
You have to know a bit about Prolog to get the joke;
you’d have to at least follow a tutorial to understand it.
But only after having once spent hours struggling to write a Prolog program that passive-aggressively outputs
False would you laugh.
The Prolog Lightbulb Joke deserves a place of honour in the Prolog community, not because of its quality as a joke, but because of the shared experience it references. I wouldn’t actually know personally, though, having had no more exposure to Prolog programming than one short course at university, plus Corey Haines’ outstanding Joy of Coding conference presentation, I don’t know Prolog and so can you.
Even without shared experience with the Prolog community, knowing enough to understand the joke brings me a little closer to them. In the broader field of software development, sharing jokes and stories between communities creates a shared culture.
When I first saw Kevlin Henney present Cool Code, his conference closing keynote showmanship looked to me like pure entertainment. I’d missed his key point, which he explained to me when we next met.
Kevlin’s presentation introduced the idea that programmers should treat historically important code as shared cultural knowledge, in the same way that other professional disciplines identify definitive examples of their craft. Meanwhile, on the Web, jokes have similar potential. But on the Web, as Weinberger points out, jokes come first.
The importance of programming jokes
Programming jokes identify community inclusion milestones. It doesn’t matter if you don’t find them funny any more, as long as you get to share the joy of someone hearing and laughing at a domain-specific joke for the first time.
You can find all of the programming jokes online, without any context. Despite this, programmers have largely failed to organise their field’s definitive jokes, and systematically teach them to new programmers. This sounds like a fixable problem.