
Andrew Barnert wrote:
I didn’t want to get into that, because I assumed you weren’t going to argue that <= makes sense for sets but < doesn’t
So you're telling about **strict** partial ordering. I can spend thousand of words, but I think Python can speak for me: ``` (venv) marco@buzz:~/sources/tests/more_itertools$ python3.9 Python 3.9.0a0 (heads/master-dirty:d8ca2354ed, Oct 30 2019, 20:25:01) [GCC 9.2.1 20190909] on linux Type "help", "copyright", "credits" or "license" for more information.
import random a = [set(), {1}, {2}, {3}, {1, 4}, {1, 4}, {3, 7}, {3, 7, 10}, {10}] random.shuffle(a) sorted(a) [set(), {3}, {10, 3, 7}, {2}, {1, 4}, {10}, {3, 7}, {1}, {1, 4}] random.shuffle(a) sorted(a) [set(), {3, 7}, {1}, {10}, {3}, {10, 3, 7}, {1, 4}, {1, 4}, {2}] random.shuffle(a) sorted(a) [set(), {3, 7}, {1}, {10}, {3}, {1, 4}, {1, 4}, {10, 3, 7}, {2}] random.shuffle(a) sorted(a) [set(), {1}, {10}, {3}, {2}, {3, 7}, {10, 3, 7}, {1, 4}, {1, 4}] random.shuffle(a) sorted(a) [set(), {2}, {3, 7}, {1}, {1, 4}, {10}, {3}, {10, 3, 7}, {1, 4}]
Notice the positions of the two {1, 4} sets......
SOooooo.... sorted(sets) does **not** sort at all. Total, partial, so and so, nothing.
Can we now stop please this OT and return to the thread?