File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
How Do I Know There is No Duplicate Keys in a "set" - a Java Collections
Joined: Nov 19, 2000
Mar 01, 2009 20:46:51
This question is about "set" under the Java Collections.
If a "set" is given to me, how do I get to know there is no duplicate keys in that "set"? Thank you.
Joined: Nov 24, 2005
Mar 01, 2009 21:11:39
A set, by definition, holds no duplicate elements (we don't say keys).
All roads lead to JavaRanch
I agree. Here's the link:
subject: How Do I Know There is No Duplicate Keys in a "set" - a Java Collections
How Do We Know that We Add Duplicate to a Set and Add Duplicate Key to a Map
How to index java objects in memory
problems about Collections
Any Link Between ArrayList and HashMap
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014