this post was submitted on 20 May 2025
204 points (94.3% liked)

Programmer Humor

23417 readers
1530 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
 

who wants pasta in their computer?

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 8 points 2 days ago (4 children)

After reading a lot of comments in this thread, I'm not sure I know what spaghetti code is. I thought spaghetti code was when the order of execution was obfuscated due to excessive jumps and GOTOs. But a lot of people are citing languages without those as examples of spaghetti code. Is this just a classic "I don't like this programming language, and I don't know much about it." Or is there something I'm missing?

[–] [email protected] 5 points 2 days ago

It’s more incredibly tangled and highly coupled code. It’s the kinda code where you can’t change anything because it causes a catastrophic cascade of issues. Basically where software engineers throw design out the window and just starting coding random bullshit that “works”

[–] [email protected] 8 points 2 days ago* (last edited 2 days ago)

Spaghetti is all messy and tangled up; spaghetti code is the same.

when the order of execution was obfuscated due to excessive jumps and GOTOs

That's one way to make your code messy and thus achieve spaghetti code.

In general, when some code is very poorly written, it becomes spaghetti code.

[–] [email protected] 4 points 2 days ago

I work in a company that has a old codebse in c with tons of realtime intime stuff that is acessed via a shared memory from the realtime to the non realtime system. Tons of strucs get copied around then typecast to other structs and global variables all over the place. You never know where a variable is written to and where it is also acessed from or if it is just a copy. No assembly but still super obscure.

[–] [email protected] 0 points 2 days ago

tbh nor am i, this is becoming vim vs emacs 2.0 isnt it