
24 Jan
2012
24 Jan
'12
9:58 p.m.
On Tue, Jan 24, 2012 at 1:25 PM, Milan Straka
I think that with intersectionWithKey, we are still holding to the mathematical idea. Imagine I have a Map Hash List. When performing intersection of two such maps, it can happen that for one hash there are different values in the maps and so in the intersection the has is not present.
Generally if the Map k a is representing a set using both k and a, the intersection on the same key can still be empty.
But Map doesn't model a set using both k and a, if it did this would hold: length (insert 1 'a' (insert 1 'b') empty) == 2 i.e. we would have a multimap. -- Johan