this post was submitted on 02 Jan 2026
551 points (97.9% liked)

Programmer Humor

30341 readers
2180 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 2 years ago
MODERATORS
(page 2) 28 comments
sorted by: hot top controversial new old
[–] Slashme@lemmy.world 4 points 2 months ago* (last edited 2 months ago)

Remember that Fortran has an arithmetic if statement. You can write

IF (expression) s1, s2, s3

where s1, s2 and s3 are labels. If the expression is negative, it jumps to s1. If it's 0, to s2 and if it's positive, to s3.

It also has goto variable. You can do

INTEGER a
ASSIGN 20 TO a
ASSIGN 17 TO a
GO TO a
20 PRINT *, "foo"
17 PRINT *, "bar"

and it'll print "bar". In this snippet of code, everything seems quite logical, but imagine debugging spaghetti code written using these patterns.

Oh, it also has

GO TO (s1, s2, ... , sn), N

First, N is converted to an integer. If N is 1, it goes to label s1. If N is 2, it goes to s2. If N is less than 1 or greater than n, it does nothing.

[–] Michal@programming.dev 2 points 2 months ago

to be fair, I think such old codebase in that ancient of a language is going to have a lot of technical debt and predate maintainable code practices. I'd rather work with a modern language. Whatherver LLM spat out - having been trained on modern code - is going to be a lot more maintainable.

load more comments
view more: ‹ prev next ›