Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Java by (7k points)
What is the difference between collections and collection in Java?

1 Answer

0 votes
by (13.1k points)

A collection is a top-level interface in the java collection framework. The collection is a member of java.util package. The collection has List, Set, and Queue as subinterfaces. There is no direct implementation of the collection but, there are direct implementations of its subinterfaces like ArrayList, Vector, HashSet, LinkedHashSet, PriorityQueue, etc.

Collections are a utility class present in java.util package. It has static methods that are used on collection. It has methods like max(), min(), sort(), shuffle, etc.

Check this java tutorial from Intellipaat to learn more.

Related questions

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...