posted 21 years ago
You would use Map.
Yes, seriously. If you have a duplicate key with a different value, how would you know which value to return for that key? You can't know. All you can do is return all the values for that key, which corresponds to a Map that maps the key to a Collection of values. The key => Collection map is once again unique.
- Peter
Peter den Haan | peterdenhaan.com | quantum computing specialist, Objectivity Ltd