this post was submitted on 15 Jul 2025
458 points (94.9% liked)

Programmer Humor

37235 readers
16 users here now

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

Rules:

founded 6 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] thann@lemmy.dbzer0.com 9 points 3 days ago (1 children)

You could use a loop to subtract 2 from the number until it equals one or zero

[–] TimeSquirrel@kbin.melroy.org 8 points 3 days ago (4 children)

Or literally just look at its binary representation. If the least significant digit is a "1", it's odd, if "0", it's even. Or you can divide by 2 and check for a remainder.

Your method is just spending time grinding away CPU cycles for no reason.

[–] webadict@lemmy.world 17 points 3 days ago (1 children)

Sorry we're not all fucking math nerds like you who knows words like "significant" or "binary" or "divide", Poindexter. Some of us make do with whatever solution is available!

[–] racketlauncher831@lemmy.ml 1 points 2 days ago (1 children)

We know you were being satire. IMO it is of decent manner if you add "/s" to be explicit so when responding a serious reply, because this is not a satire comment chain.

[–] webadict@lemmy.world 6 points 2 days ago

Sorry we're not all fucking satire nerds like you who knows words like "serious" or "satire" or "/s", Poindexter. Some of us make do with whatever solution is available!

[–] thann@lemmy.dbzer0.com 4 points 2 days ago

What should all the non binary people do then you bigot

[–] theherk@lemmy.world 4 points 2 days ago

Wasn’t the fun the CPU cycles we wasted along the way?

[–] FunkyStuff@hexbear.net 3 points 3 days ago (1 children)

are you my TA that I mentioned in the other comment

[–] TimeSquirrel@kbin.melroy.org 3 points 2 days ago

Maybe. And I can't blame it on not having had coffee when I made the comment. Just me being completely oblivious to a joke.