3 ms·
> "This is a confusing situation, and no boolean answer we could give would satisfy the principle of least surprise, so we should throw an error." Common folk
by pwdisswordfish2 7y ago
> "This is a confusing situation, and no boolean answer we could give would satisfy the principle of least surprise, so we should throw an error."
Common folk tend to disagree about whether zero is an even number. Calculating 0 mod 2 is a confusing situation, and no numeric answer we could give would satisfy the principle of least surprise, so we should throw an error.
- eru 7y agoIndeed. I didn't say the argument was a good one. Just that it was the best I found.