RSS Feed
Download our iPhone app
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.

Tip of the Day
Language: Java
Expertise: Intermediate
Jul 14, 1999



Building the Right Environment to Support AI, Machine Learning and Deep Learning

Understand the Main Interfaces of the Collections API

JDK 1.2 includes a new library of data structures called Collections. The Collections API contains object collection data structures. The Collection interface is the root interface for all the Collection classes. It basically represents a group of object called "elements." If you want to store a collection of unique elements and do not care about the order in which they are stored, use a Set. To store a collection of unique ordered elements, use a SortedSet. To store a collection of ordered elements, (not necessarily unique), use a List. To store an unordered collection of elements that are retrievable by key, use a Map. Finally, to store an ordered collection of elements that are retrievable by key, use SortedMap. The following data structures of JDK 1.1 have been replaced in JDK 1.2: Vector is replaced with List, and Hashtable is replaced with Map.
Ajit Sagar
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



Thanks for your registration, follow us on our social networks to keep up-to-date