There have been multiple accounts created with the sole purpose of posting advertisement posts or replies containing unsolicited advertising.

Accounts which solely post advertisements, or persistently post them may be terminated.

programmerhumor

This magazine is from a federated server and may be incomplete. Browse more on the original instance.

hal_canary , in FizzBuzz: Enterprise Edition
@hal_canary@lemmy.sdf.org avatar

This makes me cry.

alp , in Code that lives forever

I really think that optimization courses should have a special lecture in the optimization of optimization...

abcd , in Code that lives forever

This is so true!

Last year I had a project to upgrade the PLC of a machine to the newest generation. As usual the customer was not able to tell me the requirements they had. They told me to look in the old software…

It turns out it was 30+ years old software where you had to program in a cmd line (Siemens S5 if you know PLCs). I had to migrate everything to the next generation (S7) to be at least a little bit productive. Then I thought come on lets try to migrate to the current generation (TIA) to be even more productive.

At the end everything was nearly ready to be compiled and uploaded to the PLC. So I fixed some minor compile time issues, deleted around 50-75% of the old program (old stuff which went obsolete), changed some variable names, refactored some stuff and here we are: The same 30+ year old software is running strong. 24/7 since 6 months without issues 😁

Lanthanae , in This is not a meme, I was trying to find content for an OC /c/programmerhumor post and found this
@Lanthanae@lemmy.blahaj.zone avatar

I’d imagine it’s because people who use spaces are either further in their career in average (because the modern programming ecosystem in general uses tabs so new devs are more likely to only know that) or they’re just more serious about software development because the kind of person to die on that hill is also the kind of person who is very obsessive about other things as well.

panopticchaos , in FizzBuzz: Enterprise Edition

I had a candidate actually do that for a similar problem.

They were like 15 classes in to generate fibonacci numbers, it was wild.

aaaantoine , in This is not a meme, I was trying to find content for an OC /c/programmerhumor post and found this

That’s because these programmers are getting paid by the character.

This is also why Java dev pays so well.

ReakDuck ,

System.out.println(“Wow, so little amount of characters to print this!”);

Grishaix ,
@Grishaix@feddit.de avatar

std::cout << “Wow, so little amount of characters to print this!” << std::endl;

ElectronSoup ,

std::puts("Why do so many C++ programmers not use the right tool for the job?");

Eavolution ,
@Eavolution@kbin.social avatar

Or the slightly more readable brainfuck:

++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.

ReakDuck ,

Hey! Brainfuck is a fun puzzle language and nothing someone does at a job to do money per character. Would be funny if yes

Grishaix , in This is not a meme, I was trying to find content for an OC /c/programmerhumor post and found this
@Grishaix@feddit.de avatar

But you get smaller files with Tabs: madskristensen.net/…/performance-of-tabs-vs-space… ;)

OsrsNeedsF2P OP ,

Imagine not using a minifier

Mcballs1234 , in Rust g*me
@Mcballs1234@lemmy.ml avatar

The Linux users are in the god damn walls

0xd , in I love university

stackoverflow.com/a/5685943

Here is the answer, M$ changed their mind at some point and your university has a stale information but it seems it was true in the past.

JustANoone OP ,
@JustANoone@lemmy.world avatar

This is a reucurring theme at this specific subject unfortunately. He doesn’t seem to put much effort into it, as most slides are just plain text and nothing else. I stopped attending after the second class.

DrownedAxolotl ,

That truly sucks. Yeah, some professors can be like that. I had a math professor offer bonus points to the first 3 students completed the assignment, only for the majority to cheat and just look up the answer and turn that in. It became a contest of who could copy the fastest and one student even admitted to doing it, but she just didn’t care and gave points to the cheaters anyway.

RyeBread , in Still, better than Emacs

Say Jarvis, do you want to spend weeks fine tuning your IDE? Because boy do I have a NeoVIM for you. And boy is it glorious.

dmahtani , in Which Lemmy instance is this?
@dmahtani@lemmy.ml avatar

Bro that’s the Reddit server.

TwilightKiddy , in Yup, Javascript can go F@#! itself

This one is one of my favourite JS quirks:

JS quirk

LeFrog ,
@LeFrog@discuss.tchncs.de avatar

Wait wtf is happening there?

usernamesAreTricky ,

parseInt is meant for strings so it converts the number there into a string. Once the numbers get small enough it starts representing it with scientific notation. So 0.0000001 converts into “1e-7” where it then starts to ignore the e-7 part because that’s not a valid int, so it is left with 1

…plainenglish.io/why-parseint-0-0000001-0-8fe1aec…

PerfectParanoia , in Who is Json?

You need to be agile when you scrum on kubernetes. Especially when you react on nodejs and your json is out to lunch. Y2K was a mercy killing and we couldn’t see it.

bettse , in Yup, Javascript can go F@#! itself
@bettse@lemmy.ml avatar

This build on that humorously: www.destroyallsoftware.com/talks/wat

Bjoern_Tantau , in Yup, Javascript can go F@#! itself

Can someone explain this? I mean, the last result. Usually I can at least understand Javascript’s or PHP’s quirks. But this time I’m stumped.

mycus ,
@mycus@kbin.social avatar

JS null and undefined shenanigans


basically:

  1. bigger an lesser comparison types convert null to zero, so is zero bigger or lesser than zero? no
  2. == is fucky and to it null only equals undefined and undefined only equals null (and themselves), so no
  3. is zero bigger than or equal to zero? yeah
Bjoern_Tantau ,

Ugh, thanks, of course. Stupid brain.

mycus ,
@mycus@kbin.social avatar

I'm starting to think JS maintainers have a thing against mathematicians

Quik2007 ,

more likely against humans

  • All
  • Subscribed
  • Moderated
  • Favorites
  • [email protected]
  • random
  • lifeLocal
  • goranko
  • All magazines