this post was submitted on 05 Sep 2023
50 points (100.0% liked)

Programmer Humor

19197 readers
1181 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 31 comments
sorted by: hot top controversial new old
[–] Rhllor@feddit.de 5 points 1 year ago (1 children)

Actually had a colleague who determined distances on microscopy images that way. She would measure the scale bar included in the image with her ruler on the screen, measure the distance she was interested in and calculate the distance using the rule of three. I mean, why bother using the measuring tool included in the software.

[–] sznio@lemmy.world 1 points 1 year ago (1 children)

I've heard of people printing out charts, then cutting out the part they wanted to calculate an integral of, then weighing the paper.

[–] siipale@sopuli.xyz 1 points 1 year ago

I've heard of it too. You would need an analytical balance to get accurate measurements weighing a piece of paper. Just cut out the part you want to take an integral of, then cut out a piece of paper with known size (or cut several pieces with different sizes to get more accurate results) and weigh each of them. I guess this used to be cheaper and faster than using computers when computers were big and expensive.

[–] GlitchSir@lemmy.world 1 points 1 year ago

Just draw whitespace…

[–] gerryflap@feddit.nl 1 points 1 year ago (2 children)

People here are taking this way too seriously lol. I love Python, and I never really had any issues with the indentation being used instead of curly braces or something. This is just a silly meme, not a personal attack

[–] alphacyberranger@sh.itjust.works 2 points 1 year ago (2 children)

Precisely. It's like programmers lost their humor.

[–] DarkenLM@kbin.social 2 points 1 year ago

I have not known happiness for 12 years now.

[–] some_guy@lemmy.sdf.org -1 points 1 year ago

Had humor? /s

[–] merc@sh.itjust.works 0 points 1 year ago* (last edited 1 year ago)

Then you never had to share a codebase with someone who had different ideas about how things should be indented.

[–] knobbysideup@lemm.ee 1 points 1 year ago* (last edited 1 year ago) (2 children)

Programming languages that use white space to delimit structure are annoying at best. I get annoyed at yaml too, but I'm ok once I have a few templates set up.

[–] corytheboyd@kbin.social 1 points 1 year ago

YAML comes with its own unique pains in the ass https://ruudvanasseldonk.com/2023/01/11/the-yaml-document-from-hell

These things actually matter, come up often enough to actually be annoying, and are a bit difficult to explain and learn into people. You’re basically fine if you just string quote everything that you can, but nobody does that.

[–] mexicancartel@lemmy.dbzer0.com 0 points 1 year ago (1 children)
[–] AntEater@discuss.tchncs.de 0 points 1 year ago (1 children)

Tabs suck. Use a real editor and spaces work fine.

[–] PreachHard@mander.xyz -1 points 1 year ago* (last edited 1 year ago)

Yeah who tf isn't using tabs as spaces, it isn't 2010

[–] UrbonMaximus@feddit.uk 1 points 1 year ago (1 children)

Let me introduce you to YAML, you'll love it!

[–] lhamil64@programming.dev 1 points 1 year ago

One of these days I'll actually look up how YAML indentation works. Every time I use it it's trial and error until I stop getting errors.

[–] ipha@lemm.ee 0 points 1 year ago (4 children)

Better than counting curly braces.

[–] sentient_loom@sh.itjust.works 7 points 1 year ago (2 children)

I'll take the curly braces

[–] TheGreenGolem@lemm.ee 6 points 1 year ago (1 children)

Me too, any day. I hate everything where indentation matters. Let me just throw my garbage there and YOU sort it out, you are the fucking computer, not me. You do the work.

So fuck you, YAML! All my homies love JSON!

[–] KIM_JONG@lemmy.world 1 points 1 year ago (1 children)

All your homies hate comments.

[–] TheGreenGolem@lemm.ee 1 points 1 year ago

My code also documents itself, of course.

[–] wols@lemm.ee 1 points 1 year ago

Yup.

Spaces? Tabs? Don't care, works regardless.
Copied some code from somewhere else? No problem, 9/10 times it just works. Bonus: a smart IDE will let you quick-format the entire code to whatever style you configured at the click of a button even if it was a complete mess to begin with, as long as all the curly braces are correct.

Also, in any decent IDE you will very rarely need to actually count curly braces, it finds the pair for you, and even lets you easily navigate between them.

The inconsistent way that whitespace is handled across applications makes interacting with code outside your own code files incredibly finicky when your language cares so much about the layout.

There's an argument to be made for the simplicity of python-style indentation and for its aesthetic merits, but IMO that's outweighed by the practical inconvenience it brings.

[–] Knusper@feddit.de 2 points 1 year ago

You don't usually count them. They just have to form a neat diagonal.

[–] kameecoding@lemmy.world 1 points 1 year ago

if you have to count the curly braces I understand why you are a python developer

[–] 30p87@feddit.de 0 points 1 year ago (1 children)

Even vim can show you that
^(fucking nano user)

[–] UndefinedIsNotAFunction@programming.dev 0 points 1 year ago (1 children)

There's a joke here about using echo "some python code" > main.py in here somewhere but I can't find it. Imagine I did instead.

[–] grozzle@lemm.ee -1 points 1 year ago

"the punchline is clearly trivial, the set-up is left as an exercise for the reader"

[–] embit@feddit.de 0 points 1 year ago

He could wrap a rubber band around the screen

[–] some_guy@lemmy.sdf.org -1 points 1 year ago (1 children)

I started with Perl. This taught me a certain mindset that works well with Bash and Ruby. I've tried to learn Python several times and I just fucking hate it. I gave up when I realized that it just doesn't work the way that my brain works.

I wonder if the outcome would have been different if I'd started with Python? How might that have shaped my thinking / reasoning? Fwiw, I was also ok with PHP and SQL, but I don't know much or anything about the backgrounds on those foundations. Maybe my above statements were completely bullshit.

[–] evranch@lemmy.ca 0 points 1 year ago (1 children)

I used to love Perl as it worked the way my brain worked.

Then I started taking medication for ADHD.

I haven't used Perl since except for text parsing, it's an absolute hot mess of a language (though very powerful and functional at the things it does well)

[–] some_guy@lemmy.sdf.org -1 points 1 year ago

That's super interesting.

I have a mental divergence that isn't ADHD. I was reviewing stats on it that said people who have it are some percent more likely to have ADHD. I wonder if my previous enjoyment of Perl is because I'm on an ADHD spectrum. It would be interesting to find out.