this post was submitted on 15 May 2025
1 points (100.0% liked)

Programmer Humor

31836 readers
537 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 3 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] ricecake@sh.itjust.works 1 points 1 year ago (3 children)

I set all 8 bits to 1 because I want it to be really true.

[–] p_consti@lemmy.world 0 points 1 year ago

I was programming in assembly for ARM (some cortex chip) and I kid you not the C program we were integrating with required 255, with just 1 it read it as false

[–] laranis@lemmy.zip 0 points 1 year ago* (last edited 1 year ago) (1 children)

01111111 = true

11111111 = negative true = false

[–] StellarSt0rm@lemmy.world 0 points 1 year ago (1 children)
[–] ThatGuy46475@lemmy.world 0 points 1 year ago (1 children)
[–] assa123@lemmy.world 0 points 1 year ago

00000001 00000000 00001111 10101010

[–] palordrolap@fedia.io 0 points 1 year ago

You jest, but on some older computers, all ones was the official truth value. Other values may also have been true in certain contexts, but that was the guaranteed one.