True it is! Mwahahahahaahah!
When you ask someone a boolean question....... and they return a string
Submitted 2 weeks ago by beep@piefed.world to [deleted]
Comments
idunnololz@lemmy.world 2 weeks ago
When you ask someone an enum question and they return a boolean.
Badabinski@kbin.earth 2 weeks ago
A string with length > 0 is truthy*, so we're good!
*in python
ReluctantMuskrat@lemmy.world 2 weeks ago
False is true!
gnufuu@lemmy.ca 2 weeks ago
Yeah, better avoid those types
LeFrog@discuss.tchncs.de 2 weeks ago
ELI5?
Badabinski@kbin.earth 2 weeks ago
In programming languages, data comes in different forms. If you want to get a yes/no answer to something, there's a way to represent that: a true/false boolean. If you want to get a street address, that's a string, because it's just a big ol blob of undifferentiated text to the computer.
The joke is about how you ask someone a yes or no question, but they respond with something which is not either of those options.
dismay3915@lemmy.world 2 weeks ago
This belongs to programmer humor. Don’t let us drop type theory and category theory on these poor non-programmers
Kenny2999@lemmy.world 2 weeks ago
Unless the question is “did you buy any clothes, dear?”
python@lemmy.world 2 weeks ago
Deep down, it’s all [Object object] anyways
one_knight_scripting@lemmy.world 2 weeks ago
I object to your statement.