|
|
|
|
|
by robot_no_421
1032 days ago
|
|
> What’s important is what kind of operation you want for when implementing algorithms, and False is what I always want in cases where I do “all”. Why would you want "all" to produce results that are inconsistent with logic and mathematics? Consider this tautology, which is a result of De Morgan's laws: for any list L, we have that all(L) == ~any([~x for x in L]). In other words, if all([]) == False, then you would also logically need to accept that: False == all([]) == ~any([~x for x in []]) == ~any([]) which means that we'd require any([]) == True. And that's definitely an illogical result. |
|