this post was submitted on 08 Apr 2025
376 points (98.2% liked)

Programmer Humor

22354 readers
2774 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
 
top 14 comments
sorted by: hot top controversial new old
[โ€“] [email protected] 31 points 5 days ago (1 children)

Fortunately you're likely to run out of memory or swap space and it will stop all by itself ๐Ÿ˜‡

[โ€“] [email protected] 19 points 5 days ago (1 children)

tail call optimization wants to know your location

[โ€“] [email protected] 11 points 5 days ago (2 children)

I've been writing software for over 40 years and this is the first I have ever heard of this. Much appreciated.

I'm still trying to grok it, but for anyone playing, here's where I started:

https://stackoverflow.com/questions/310974/what-is-tail-call-optimization#310980

[โ€“] [email protected] 7 points 5 days ago (1 children)

i am glad my shitposting was educational

though tbh you're unlikely to ever need this knowledge unless you're heavily into functional programming or golfing or coding interviews or other esoteric arts

[โ€“] [email protected] 2 points 5 days ago
[โ€“] [email protected] 5 points 5 days ago (1 children)

Functional programming would have quite the problem if it wasn't a thing.

[โ€“] [email protected] 4 points 5 days ago (1 children)

It's funny. When I first started, functional programming was going to be the next big thing. It bubbled along for a decade or so. I interviewed company founders about their functional software projects.

Nothing happened.

Sure there are a few, let's call them niche, applications, but you just have to look around and see that object orientation made a bigger splash and even that is beginning to be evaluated.

Perhaps functional software will have its day in the limelight, but with the latest AI slop fad, it's going to be a while.

[โ€“] [email protected] 3 points 5 days ago

The of the ideas of functional programming have gone on to influence the field.

Algebraic data types and monads are used heavily in Swift/Rust/Scala/Typescript.

Concepts like left/right associativity and pure functions are critical to the entire MapReduce paradigm of computing. Apache Spark, pandas, and the entire dataframe programming paradigm is basically functional programming (though most people suck at pandas and treat it like an object oriented tool).

I think a lot of React is also heavily inspired by functional programming, and modern concurrency schemes are inspired by functional programming.

F# and Haskell didn't win the language wars. I've worked on one erlang project and it was neat, but I think you're right, I mostly see MVC apps.

[โ€“] [email protected] 9 points 5 days ago

Could be worse. I once experimented with a debug-level function that ran on every line of text printed to the console. And had a typo, which threw an error. Which printed to the console.

[โ€“] [email protected] 5 points 5 days ago

until your stack runs out of memory

[โ€“] [email protected] 3 points 5 days ago (1 children)

I had this problem only once. Luckily, I do not need recursion. I know my way using iterative process.

[โ€“] [email protected] 1 points 5 days ago (1 children)
[โ€“] [email protected] 1 points 3 days ago

I actually use repeat(iterations,index_name(optionall),);. No need for i++ or ++i for loop in many cases.

[โ€“] [email protected] 1 points 5 days ago

He's not making the function call past n-1