320
submitted 3 months ago by yogthos@lemmy.ml to c/programmerhumor@lemmy.ml
top 15 comments
sorted by: hot top controversial new old
[-] RalphWolf@lemmy.ca 18 points 3 months ago

Document your code like the guy who will be maintaining it is Dexter, and he knows where you live.

[-] Aurenkin@sh.itjust.works 14 points 3 months ago* (last edited 3 months ago)
// This function calculates applicable discounts given a customer's loyalty status
// STOP BEFORE SEASON 8 DEXTER PLEASE 
fun calculateDiscountRate(loyalty: LoyaltyStatus): Set<Discount> {
    // No seriously you can hide out at my place if you need to just please don't let them do it 
...
[-] NeatNit@discuss.tchncs.de 7 points 3 months ago

That ... at the end made me think there was more code and my client was refusing to show it to me no matter what I did.

[-] AnnaFrankfurter@lemmy.ml 2 points 3 months ago

And don't watch that new dexter spin off

[-] original_reader@lemm.ee 8 points 3 months ago

Document your code. Or even better in many cases, write more self-documenting code.

[-] electricprism@lemmy.ml 8 points 3 months ago

Is this going to activate the StarGate?

[-] bobs_monkey@lemm.ee 6 points 3 months ago

Only one way to find out

[-] xmunk@sh.itjust.works 7 points 3 months ago

Excuse me, but my indecipherable hieroglyphics at least use proper indentation.

[-] HubertManne@moist.catsweat.com 5 points 3 months ago

I get this one so much. I don't consider myself a developer because I tend to just touch code but that means I won't touch any for weeks. Worse I tend to do a lot of poc or boot strapping type of things and so its like there was a user story last pi to check the feasibility of something and now have a user story to get it regularly working in a poc env and I have forgotten everything about that particular system or language or whatever.

[-] pfm@scribe.disroot.org 1 points 3 months ago

That's why we keep notes... Literate DevOps is a solution for my preferred editor, but there definitely are solutions for other tools too, even if they don't work exactly the same.

I can't recommend keeping notes too much.

[-] HubertManne@moist.catsweat.com 2 points 3 months ago

I mean thats great but finding the notes is always a chore to because so much has been done between now and then and there are a lot of stuff done with their own notes. We are actually required to document in like 3 different ways although we don't need to do all 3 all the time. informal, formal internal, formal customer.

[-] pfm@scribe.disroot.org 2 points 3 months ago

I'm not going to argue, because I don't know your work environment, but the notes I mentioned weren't supposed to be published or attached to the product. They're more of a personal knowledge base, where you can look up former approaches, issues found in the past, reasoning, decisions with context... All the zettelkasten tools out there do exactly that: help maintaining a useful knowledge base.

[-] vampira@lemmy.eco.br 3 points 3 months ago

If I get off my computer for an hour and come back I'm already unable to recognize my code lol

[-] qprimed@lemmy.ml 1 points 1 month ago

this resonates so much...

"ok, which one of you crackheads decided an unconstrained recursive C function was a good idea right her... oh."

[-] biggerbogboy@sh.itjust.works 2 points 3 months ago

this was me while writing my website for my screen and media course, I come back a week later and try to interpret these ancient runes inscribed on my IDE, had to stare at it for like half an hour to finally get what I made.

this post was submitted on 02 Aug 2024
320 points (100.0% liked)

Programmer Humor

32358 readers
359 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS