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.

programmer_humor

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

tja , in Sometimes the decisions are hard...
@tja@sh.itjust.works avatar

Let’s skip that version, I didn’t think there are that many new features in there

dustyData ,

But think about the security updates.

hddsx ,

Yes, 0.7.1 fixes redundancy issues present in 0.7.1 when updating 0.7.1.

victorz , in You wouldn’t get it

Ha. Cause there’s no getter. I get it. I think?

dohpaz42 ,
@dohpaz42@lemmy.world avatar

I get it.

No you don’t; there’s no getter.

victorz ,

Oh, now I get it.

Wait…

Batman ,

You don’t get the context of this joke

fsxylo ,

var context = getContext();

lightnegative ,

var context = RuntimeSingletonFactory.getCurrentFactory().getCurrentRuntimeSingleton().getContext()

4am ,

It’s also an inside Joke

intensely_human ,

And the Joker gets it, but you don’t.

sbv , in The Holy Trinity of JavaScript

Sorry, 0 == ‘t’? What?

Limitless_screaming , (edited )
@Limitless_screaming@kbin.social avatar

that's not "t", it's "\t" which is just a tab. There's also "\n" for newline.

MinekPo1 ,
@MinekPo1@lemmygrad.ml avatar

yeah but why is a single character string containing a tab equal to zero ???

Limitless_screaming , (edited )
@Limitless_screaming@kbin.social avatar

That would be weird if a string containing a space wasn't equal to 0 " " == 0, but that's not the case in JS. If you think that "" and " " being equal to 0 is weird then I agree, but since they are, you should expect "t" and "n" to equal 0 too.

Ephera ,

The == operator in JS will try to cast the things being compared and do all kinds of ‘smart’ assumptions about what equality means. This is why everyone uses === instead…

8bitguy ,

Unless you enjoy inviting the chaos.

Sonotsugipaa ,

It still makes no sense though

Limitless_screaming ,
@Limitless_screaming@kbin.social avatar

If " " wasn't equal to 0, it wouldn't make sense, but since a string containing a space equals 0, you'd expect the same to apply to a string containing a tab or a newline. (or at least I'd expect that)

FaceDeer ,
@FaceDeer@kbin.social avatar

I admit I have never dabbled in javascript, despite being a proficient programmer. I now dread to ask... would any string that contains only whitespace == 0? " \t\n \t " for example?

Limitless_screaming ,
@Limitless_screaming@kbin.social avatar

Yes, it would. Just like a string of spaces " " == 0, but it isn't that bad; === is Javascript's version of == in other languages, and, thus, you should be using it if you don't want that wonkiness.

== is just for convenience, like when you want to make sure that the user didn't leave the form empty and the button shouldn't be greyed out, and other UI stuff. Without these kinds of features JS wouldn't be used in so many toolkits.

atx_aquarian ,
@atx_aquarian@lemmy.world avatar

Ok, I always mistakenly assumed === was the identity operator in JS, too. TIL, thanks! As much as we like to poke fun at JS, every time I’m taught the rationale behind some aspect of it, I find it redeeming and even a little endearing.

bitcrafter ,

The explanation given to you makes it sound like == was deliberately designed to be a more convenient version of ===, but what actually happened was that == used to be the only equality operator in JavaScript, which meant that if you didn’t want it’s auto-coercing behavior then you needed to go out of your way to add additional type checks yourself. Because this was obviously a tremendously inconvenient state of affairs, the === operator was introduced later so that you could test for equality without having to worry about JavaScript doing something clever underneath the hood that you weren’t expecting.

masterspace ,

The explanation given to you makes it sound like == was deliberately designed to be a more convenient version of ===

I mean technically == was deliberately designed to be a more convenient version of other languages’ == operator… Just specifically more convenient for light UI stuff since that was all JavaScript was supposed to be used for at the time (or all they thought it would be used for).

But give programmers a way to write and execute a small script and someone will eventually use that to try and write an emulator that emulates the computer it’s running on, so the web evolved into more complicated applications, and then that convenience turned out to be wildly inconvenient, not to mention horribly unexpected for programmers coming from other languages, so then they added the triple equality to match other languages.

sbv ,

It’s a slash-t in the comment. Maybe kbin has different rendering rules for comments?

https://sh.itjust.works/pictrs/image/7026f17a-f237-49d3-8d80-28632876acdb.png

Limitless_screaming , (edited )
@Limitless_screaming@kbin.social avatar

Oh, in that case I replied to @MinekPo1 with my answer to that. BTW can you see the slash in: t and "t".

sbv ,
Limitless_screaming , (edited )
@Limitless_screaming@kbin.social avatar

My bad. I just edited it. "t" t It's displaying correctly on Lemmy.world. So it seems like another Kbin only issue.

jtk ,
@jtk@lemmy.sdf.org avatar

Yeah, it’s true. I knew all the other ones, had to put that one in the dev tools console to believe it. I was just happy to know === continues to be sane in that comparison.

Blackmist ,

You have to remember that the underlying principle of JavaScript seemed to be “never throw an error”, even if what it’s being told to do is weapons grade bollocks.

BassaForte , in You wouldn’t get it
@BassaForte@lemmy.world avatar

public Joke Joke { private get; set; }

Kolanaki , in You wouldn’t get it
@Kolanaki@yiffit.net avatar

Stop making private jokes and start posting them publicly. We wanna laugh too, ya selfish bastid.

Trikami , in He revealed the secrets !

wait, you guys don’t use ones and zeroes?

vk6flab ,
@vk6flab@lemmy.radio avatar

No, that’s several abstraction layers down … there’s libraries for that.

Sonotsugipaa ,

No, just base-256 numbers that for some reason people call “binary”

KillingTimeItself , (edited ) in He revealed the secrets !

im convinced most developers spend more time working on making shit work, rather than actually writing code and bugfixing it.

edit: this was mostly a shitpost, and i was expecting some flack, but i got basically none. Can we have a real moment here. Are you guys doing ok? Who made you do this to yourselves?

ok, real talk over, we’re going back to suffering now.

jubilationtcornpone ,

Half the time it’s trying to figure out where to apply the next piece of duct tape to keep the entire house of cards (and duct tape) from collapsing.

KillingTimeItself ,

damn.

Buttons ,
@Buttons@programming.dev avatar

In times past they got shit done, and now we see that what they’ve done is shit and we’re stuck maintaining it.

szczuroarturo ,

Yup. Thats just enterprise software for you. Something was made requiremnts changed, and then changed again and then ypu have duct tape on top of a duct tape with a duct tape holding those duct tapes and a touch of super glu here and there. Also ducttapes are microscopic in size but the sheer quantity of them is unimaginable.

KillingTimeItself ,

this part is pretty much expected i think. But i’m starting to see it cropping up into the more meta aspects of programming now. For instance, apps being shipped with existing deprecated packages. Seems like it’s also creeping a little further into the more UI aspects of it as well.

JustBrian7872 , in You wouldn’t get it

They don’t call me AbstractJokerAdapterFactoryProxy for nothin’

psion1369 , in He revealed the secrets !

I used to joke with my niece that my programming job was just me staring at screens and meetings all day. She didn’t believe me until she got to shadow me one day and got super bored.

dan1101 ,

But when your brain is fascinated by all that has to happen for those screens and meetings to happen, it can still be an interesting job.

BurningTurtle ,
@BurningTurtle@programming.dev avatar

What did she think before?

whotookkarl ,
@whotookkarl@lemmy.world avatar

Not op but guessing she had an idea from media like TV shows and movies that make technical jobs seem much more exciting for entertainment over realism. Crises are usually more Jerry accidentally deleted a directory and we need to recover some files and establish safe guard procedures to prevent it from happening again or this thing broke that nobody even knew existed so we gotta figure it out and less type fast enough to save the mainframe from l33t hackers.

mormegil ,
@mormegil@programming.dev avatar

It’s not as easy as it sounds, sometimes the screens are all wrong!! xkcd.com/722/

KindaABigDyl , in He revealed the secrets !
@KindaABigDyl@programming.dev avatar

I agree with the last point tbh

At the bare minimum, if you aren’t capable of contributing to the library you use, then you don’t deserve to use it.

xmunk ,

I disagree, if you aren’t capable of contributing to a library you should be required to use it rather than roll your own solution.

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

Nah you should learn

force ,

Because software devs have the weeks/months to learn vulkan every time they want to use a GUI for their job, or to learn compiler design whenever they wanna use java for their job

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

to learn vulkan every time they want to use a GUI for their job

Not every time, just the first time. But yes. Devs should stop being so lazy

compiler design whenever they wanna use java for their job

Every dev should at least know the basics of language design and compiler design, yes. Again, you also only have to learn it once

indepndnt ,

Honestly, why? We’ve got billions of people driving around in cars they don’t know how to build. Is that a problem too?

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

Yeah. Kinda actually

xmunk ,

As someone who has written a DB handle… that shit is hard, I had to be extremely careful to protect against SQL injection. Everyone rolling their own is how we return to the Era of XSS and SQL Injection on every website. I’d prefer to have young devs use libraries and contribute as they gain knowledge.

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

that shit is hard, I had to be extremely careful to protect against SQL injection

People need to learn to be careful

xmunk ,

They do… but the road to naturally learning that lesson comes with the cost of enabling botnets and destroying businesses. Maybe there should be a qualification exam to be a developer but when there isn’t we need to make sure more junior developers have the best tools they can get to fight against foot guns.

Also, on the topic of security, a lot of good senior level developers don’t have the specialized knowledge to do shit like build a password validation system that isn’t vulnerable to a timing attack or know what a timing attack is…

And timezones, fuck timezones, I’ve written code that correctly handled timezones (and subsequently threw it away when Canada decided to DST on a different weekend). Imagine how shitty it’d be if we constantly had to reinvent the wheel when it came to timezones.

Oh, and forget about databases… do you know how fucking hard it is to write an ACID compliant WAL? The reason postgres is the default open source database (and why so many databases are just layers built on top of postgres’s engine) is because it’s fucking hard. Mongo still (IIRC) has consistency issues, they were a tech darling for half a decade and can’t manage to NoSQL as well as Postgres.

Also, good luck building a GUI with anything more complicated than curses style box art characters.

I started mildly disagreeing with you but I disagree even more that I’ve thought about other tools people would need to roll on their own.

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

a lot of good senior level developers don’t have the specialized knowledge to do shit like build a password validation system that isn’t vulnerable to a timing attack or know what a timing attack is

Please don’t tell me that. It’s terrifying

Valmond ,

The best developers are the laziest.

I’d take a dev slowly using a library with a one liner than a noob writing 500 lines of code doing the same thing any day.

KindaABigDyl ,
@KindaABigDyl@programming.dev avatar

That’s how you end up with the unmaintainable state that enterprise software is currently in. “Just Works” mentality is a cancer

CausticFlames ,

Where’d you buy this brand of bait?

Valmond ,

If you just knew how many libraries we use…

Anticorp , in Junior Dev VS Senior Dev

Dual monitors are so 2000’s. It’s all about the single large ultra-wide monitor now. You get the benefits of a dual monitor setup without the line in the middle and the RSI neck pain issues.

Skullgrid ,
@Skullgrid@lemmy.world avatar

but can you do the double click maximise thing? EDIT : or the “windows” + arrow to other screen thing?

Anticorp ,

Yup!

Obi ,
@Obi@sopuli.xyz avatar

Yep and in Windows 11 you now have premade window placements so if you hover the maximise button you can select e.g. “right hand, one third width” and another program for “left hand, two thirds width” etc. I use it all the time. I do have a second monitor on top of the ultra wide but mainly because it’s a special colour accurate monitor, for productivity I was doing fine with just the one big UW for years.

Jakeroxs ,

Check out PowerToys fancyzones feature if you haven’t yet.

Obi ,
@Obi@sopuli.xyz avatar

I did check it out at some point but didn’t stick with it, can’t remember why.

RamblingPanda ,

I bought an ultra wide at the beginning of COVID and when I started my new job, my employer gave me another one. Now I have two side by side (the newer one is in the middle) and my laptop to the side. Sometimes I struggle to open enough applications to fill all that space.

fidodo ,

I prefer a single ultra wide because it doubles as a dock. I can get all my USB devices and laptop power connected with a single USBC cable.

Anticorp ,

There’s that too. With USB ports it can operate as a pseudo KVM between a desktop and a laptop.

porgamrer , in He revealed the secrets !

Wait until this guy finds out that Elon doesn’t actually build the cars

pancakes ,
@pancakes@sh.itjust.works avatar

Or contribute to society at all really

fsxylo ,

Seriously. If Elon shut down Tesla tomorrow all these engineers would be building electric cars at other companies.

brbposting ,

Does (or does not) he get the credit for committing the fraud that kept Tesla in business long enough to popularize* electric cars that there are other companies at which to build them?

Aforementioned fraud:

https://sh.itjust.works/pictrs/image/8de67f72-d86d-4ce8-8045-37b0b60d6a6f.png

(When searching, found apparently jurors in 2023 disagreed with my assessment, so please take with grain of salt.)

*I say “popularize” given:

Tesla was incorporated in July 2003 by [not Elon! but] Martin Eberhard and Marc Tarpenning as Tesla Motors.

LordKitsuna ,

He’s a piece of shit but he restarted the Space Race that was literally dying, push the industry into electric cars when none of them were willing to do it. His actual products may be garbage but it doesn’t stop that it started the movements that needed to happen in the industry.

To say that he contributed nothing at all is unfortunately false as much as I may hate the man

AdmiralShat , in Tattoo Idea

“I have the IP address of the man who ruined my life forever on my hands”

Pulptastic ,

Don’t believe his lies

Dnn ,

127.0.0.1 then?

GreyCat ,

That’s his loopback address, his local IP can be 192.168.0.1/24

fourwd , in Junior Dev VS Senior Dev
@fourwd@programming.dev avatar

Used dark (not black) themes everywhere for 8 years. My eyesight is still good according to my annual physical, but recently I’ve noticed that I have a hard time reading text written on a dark background. It is slightly blurred, especially when there is no light in the room.

Somewhere I still use dark themes, but I always try to switch to light mode if things look okay with code highlighting or smth.

bandwidthcrisis ,

Physical? As in a medical exam with a doctor?

If so you should really have a check up with an eye doctor, there are lots of eye health tests that you should regularly get beyond checking that you can read a chart at a distance.

superfes ,

This right here, guy is like “I can’t see the light shooting at my eyes, but every thing is okay otherwise, I’ll just live with it.”

Miaou ,

That’s unfortunately what a lot of ophtalmologist (and other medical doctors) end up saying when they don’t know what’s wrong with you.

oldfart ,

They do, I really hear you. I don’t bother going to a doctor for the exhausting fatigue.

But with eyes not seeing well after 8 years of looking at a screen, you’re not an odd case, you’re the same as half of the society. It’s either short sightedness, far sightedness or astigmatism.

Rolder ,

For me, it’s light mode for work and dark mode at home.

yamanii , in He revealed the secrets !
@yamanii@lemmy.world avatar

Hey dude stop it spreading it okay?

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