collection Vs Collections ???

Collection : The root interface (interface : blue print of class).The List, Set, and Queue are the main sub-interfaces of the collection interface.

Collections : A class which has static methods.It defines several utility methods like sorting and searching which is used to operate on collection.

Interface can contain static methods since java 8 . Before that it wasn't allowed . Now interface has static methods, default methods and abstract methods.

Collection extends Iterable interface while Collections extends Object class.

SIMILARITY

# They are found in same java.util package.

# They are added in java jdk version 1.2.

# They are part of Java Collections framework.

SYNTAX

Collection Interface

public interface Collection<E> extends Iterable<E>

Collections class

public class Collections extends Object

INTERVIEW

Java Collections Framework is one of the core APIs of java programming language. It’s one of the important topics for java interview questions. Recently i appeared for an interview. Out of 7 , 4 questions were related to Java Collections Framework.