It’s no wonder that conditionals (and with them, booleans) are so widely despised!
They are? It’s no wonder that conditionals (and with them, booleans) are so widely despised!
They are?Even standard algorithms like quicksort[1] use conditionals.
And, while I can see how massive switch statements suck, normal conditionals are common in everyday life: "If they don't have a dark roast coffee, get me a medium roast."
All of which is to say, I really don't understand what he's getting at. The last example he gave seemed to make things even more complicated, and it basically renamed "true" and "false" to more descriptive things (forRealOptions, dryRunOptions), which seems to my untrained eye to boil down to the moral equivalent of a C enum.
"They had dark roast so I got you nothing as requested."
IOW, this program is either incomplete or wrong. Cf. "Get me the darkest roast they have." - ifless, concise, robust.