this post was submitted on 08 Feb 2026
26 points (100.0% liked)
Programming Horror
2301 readers
4 users here now
Welcome to Programming Horror!
This is a place to share strange or terrible code you come across.
For more general memes about programming there's also Programmer Humor.
Looking for mods. If youre interested in moderating the community feel free to dm @Ategon@programming.dev
Rules
- Keep content in english
- No advertisements (this includes both code in advertisements and advertisement in posts)
- No generated code (a person has to have made it)
Credits
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Indeed. But...
If One was defined as random garbage, then still...
Zero=One-One
See my definition of One afterwards, it's a bit awkward, but works..
I'm not super familiar with BASIC. Can you explain how the definition of One works? If variables have random values when declared but not set due to memory garbage, I would expect ZeroBit to be "true" half the time and "false" the other half. When it's false, I can reason through it, but when it's true I don't see it. I imagine it has something to do with the details of ABS()?
Different BASIC dialects work differently, you're absolutely right to ask.
Honestly, the ZeroBit code part is the hack within Mobile Basic, it always returns Zero, meaning the ABS(NOT(ZeroBit)) will always return One