July 24, 2019
10:36 a.m.
Op 24 jul. 2019 om 02:27 heeft Steven D'Aprano <steve@pearwood.info> het volgende geschreven:
But I can suggest at least one useful invariant. If a, b are two dicts:
a.items() == b.items()
ought to be equivalent to:
(a.keys() == b.keys()) and (a.values() == b.values)
I don’t think this invariant holds unless comparison is order dependent. {1:2, 3:4} and {1:4, 3:2} have the same keys and values, but not the same items. Ronald