Paul Clapham wrote:Yes. A Map simply isn't a collection so there is no reason why it should implement Collection.
Also, you could ask yourself how the Map<K, V> interface could possibly implement the Collection<E> interface. When you see it stated in generic terms it's easier to see that it doesn't make sense.
hi Paul, There should be a reason for each and everything. Without reason, nothing will exist/happen. could you please provide more information on "Also, you could ask yourself how the Map<K, V> interface could possibly implement the Collection<E> interface. When you see it stated in generic terms it's easier to see that it doesn't make sense." I am not clear