this post was submitted on 21 Sep 2023
1271 points (94.8% liked)

Programmer Humor

19512 readers
314 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS
 
top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 133 points 1 year ago (7 children)

This could be so much longer.

Killing children, class systems, so many programming language names, the ridiculous ways equality and order-of-operations are done sometimes. Plenty of recursion jokes to be made. Big O notation. Any other ideas?

[–] [email protected] 37 points 1 year ago (1 children)
[–] [email protected] 42 points 1 year ago (2 children)

GOTO is the only thing that makes sense. It's the "high-level" concepts like for-loops, functions and list comprehension that ruined programming.

series.append(series[k-1]+series[k-2]) for k in range(2,5)]

RAVINGS DREAMT UP BY THE UTTERLY DERANGED

[–] [email protected] 15 points 1 year ago (1 children)

I started coding with TurboBasic, which included the helpful innovation of GOTO {label} instead of GOTO {line number}, which allowed you to have marginally-better-looking code like:

GOTO bob
...
bob:
{do some useless shit}
return

which meant you essentially had actual, normal methods and you didn't have to put line numbers in front of everything. The problem was that labels (like variables) could be as long as you wanted them to be, but the compiler only looked at the first two letters. Great fun debugging that sort of nonsense.

load more comments (1 replies)
[–] [email protected] 15 points 1 year ago* (last edited 1 year ago) (1 children)

if goto make sense why don't you go to get some bitches

[–] [email protected] 12 points 1 year ago* (last edited 1 year ago)

Because "get some bitches" is an invalid instruction

[–] [email protected] 32 points 1 year ago

Big Orgasm notation

[–] [email protected] 19 points 1 year ago

A monad is just a monoid in the category of endofunctors.

[–] [email protected] 11 points 1 year ago* (last edited 1 year ago) (1 children)

Masters and slaves

Cloning

Deploying code (that's what you do with soldiers!!!1)

Using Git to rewrite history.

Atomic values (like the bomb!)

These people are madmen.

[–] [email protected] 7 points 1 year ago

One of the slave node's child process failed, so the master node sent a signal to terminate the child and restart the slave

There's pretty solid reason my research group is pushing to use "head node and executor nodes" nomenclature rather than the old-school "master node and slave nodes" nomenclature, haha

load more comments (3 replies)
[–] [email protected] 120 points 1 year ago* (last edited 1 year ago) (3 children)

while (true) { print(money) }

isn't that just crypto mining?

[–] [email protected] 28 points 1 year ago (1 children)

Three years ago, yes. Now? not so much.

[–] [email protected] 12 points 1 year ago (3 children)

i mine monero while idle and it prints a massive 0.03GBP a day :)

[–] [email protected] 15 points 1 year ago (2 children)

Serious question, wouldn't it be cheaper to buy it?

[–] [email protected] 16 points 1 year ago
[–] [email protected] 8 points 1 year ago

given i have solar panels, it's technically free money.

load more comments (2 replies)
[–] [email protected] 13 points 1 year ago

JavaScript will actually open the print dialog.

load more comments (1 replies)
[–] [email protected] 34 points 1 year ago (6 children)

I actually have that teapot and I use it several times a week.

[–] [email protected] 10 points 1 year ago (1 children)
[–] [email protected] 14 points 1 year ago* (last edited 1 year ago) (2 children)

Thanks! In computer graphics it's referred to as the "Utah teapot" because the 3D model was created at the University of Utah. But it was originally a Melitta brand teapot. It is still manufactured by German company Friesland, which I bought it from.

Unfortunately it appears they recently had a fire and their webshop is temporarily closed, but I think you can also get it off of Amazon.

load more comments (2 replies)
load more comments (5 replies)
[–] [email protected] 28 points 1 year ago (3 children)

Cat is a fluffy animal, not for reading shit

[–] [email protected] 8 points 1 year ago

Writing 'echo' cannot do anything. Everyone knows echo works with sound only.

load more comments (1 replies)
[–] [email protected] 25 points 1 year ago (1 children)

Enough people have thought of while (true){ print(money); } for manufacturers to have built stuff into printers to prevent that, alas.

load more comments (1 replies)
[–] [email protected] 23 points 1 year ago (3 children)

Can someone explain this joke to me

"I'm writing a recursive method with threads to optimize the CPU usage in a 0.02%"

I understand everything apart from the "in a 0.02%". What does that mean? How can something be in a percentage?

[–] [email protected] 39 points 1 year ago

It's a nonsensical statement to us programmers too.

[–] [email protected] 24 points 1 year ago

I think they meant « by ».

[–] [email protected] 8 points 1 year ago (1 children)

It's a double joke. For programmers, it's pretty useless unless your in high performance computing.

If you're on the nitty gritty OS or CPU itself, 0.02% optimization can mean significant improvememt of different things but because it is otherwise unitless, it is equally useless to the reader.

load more comments (1 replies)
[–] [email protected] 20 points 1 year ago* (last edited 1 year ago) (2 children)

Socrates said books were dumbing down humanity because, since people could just look things up in books they wouldn’t have to memorise information anymore, and that made their brains soft.

Ever since society began, some people have been convinced the next generation’s technology was going to be society’s downfall, whether it was Socrates’ books, the telegraph in the 1800s, radio, the (land line) telephone, dishwashers (women will become lazy and unsuitable wives and mothers), screened windows (society will collapse because you won’t hear your neighbours and pedestrians on the street, we’ll all become hermits and die holed up in our homes), comic books would rot the brains of the youth, then music, then video games… it goes on and on.

So far, those predictions have never been true. Every older generation freaks out when the ones after come of age. It’s like societal growing pains.

[–] [email protected] 7 points 1 year ago (2 children)

I think this is one step further, that technology has become so abstract and complex that people who focus on different crafts and careers are using magical black boxes. It blows my mind how my neighbour goes through life without any concept of what a phone app is. He just uses functionality and memorized the associated logo. I'm an engineering wizard to him.

load more comments (2 replies)
[–] [email protected] 6 points 1 year ago* (last edited 1 year ago) (3 children)

Some technologies actually have had unintended side effects, but not always the ones we saw coming. Artificial lights are killing all the insects which nobody really worried about and cars do kill tons of people, which we worried about in the 1920s. I don't know what the deal was with leaded gasoline, that one was just bizarre.

All in all, it's just really hard to anticipate how society and technology will interact. We think about the environment now but I don't know if any systematic progress has been made on predicting the human factor.

screened windows (society will collapse because you won’t hear your neighbours and pedestrians on the street, we’ll all become hermits and die holed up in our homes)

This one has actually come true to a certain measurable degree (see Bowling Alone, written at what is now the midpoint of the trend), but I don't think it's down to window screens.

load more comments (3 replies)
[–] [email protected] 14 points 1 year ago (3 children)

Increasing the CPU optimization by 0.02% does seem crazy to me. If you're going to spend time working on something, make it worthwhile. Also, isn't while(true) {print(money)} Microsoft, Apple and Amazon:s business model?

load more comments (3 replies)
[–] [email protected] 11 points 1 year ago* (last edited 1 year ago) (2 children)

while{true}{print "money"};

moneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoney

[–] [email protected] 6 points 1 year ago (2 children)

moneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoney

load more comments (2 replies)
load more comments (1 replies)
[–] [email protected] 11 points 1 year ago (1 children)

I bet ATMs would have a while true print money function

[–] [email protected] 7 points 1 year ago (1 children)

Almost:

While (hasMoney())
Print(money)

load more comments (1 replies)
[–] [email protected] 8 points 1 year ago

Math professorss be like:

[–] [email protected] 6 points 1 year ago (4 children)

To make things worse, that teapot doesn't have a bottom surface.

load more comments (4 replies)
[–] [email protected] 6 points 1 year ago* (last edited 1 year ago) (1 children)

I always wonder what the original post was. Something like "Stop doing science!" or some shit but seriously rather than sarcastically.

[–] [email protected] 29 points 1 year ago (2 children)
[–] [email protected] 6 points 1 year ago

Ah ha! Thanks, I thought this spawned on some conspiracy facebook group

load more comments (1 replies)
load more comments
view more: next ›