Tag: Java data structures

View All Collections

November 23, 2013 · 2 min read
**Advise for a fresher**

Common Elements Existence disjoint()

August 28, 2011 · 2 min read
The method, **disjoint()**, of [Collections class](http://way2java.com/collections/collections-api-methods/) returns **true** if the two data structures under comparison does not have any elements in common. At least, one element is common in the both, it returns **false**. **disjoint()** method is very useful to compare (to know the existence of common elements) two [lists](http://way2java.com/collections/list-fundamentals/) or [maps](http://way2java.com/collections/interface-map-tutorial/) or [sets](http://way2java.com/collections/interface-set-tutorial/).