To get TreeSet Element Greater than Specified Element using ceiling() Method in Java. The ceiling method in Java return the least element in the set… Read More
Tag Archives: Java-Collections
TreeMap class is like HashMap. TreeMap stores key-value pairs. The main difference is that TreeMap sorts the key in ascending order. TreeMap is sorted as… Read More
A LinkedList is a linear data structure, in which the elements are not stored at contiguous memory locations. For converting a linked list to a… Read More
The Java.util.LinkedList.removeFirst() method is used to remove the first element from the LinkedList. The Java.util.LinkedList.removeLast() method is used to remove the last element from the… Read More
A PriorityQueue is a linear data structure in which the elements are ordered according to their natural ordering or by some custom comparator provided at… Read More
TreeMap is a part of the Java Collections framework. Java TreeMap contains values based on the key. It implements the NavigableMap interface and extends AbstractMap… Read More
ArrayBlockingQueue class is a member of the Java Collection framework. ArrayBlockingQueue is a bounded blocking queue. The term bounded, means that the size of the… Read More
In Java, objects are stored dynamically using objects. Now in order to traverse across these objects is done using a for-each loop, iterators, and comparators.… Read More
Primitive types are the most basic data types available within the Java language. Such types serve only one purpose — containing pure, simple values of… Read More
The enumeration in java is one of the predefined interfaces, whose object is used for retrieving the data from collections framework variable(like Stack, Vector, HashTable,… Read More
The ArrayDeque in Java provides how to use resizable-array additionally to the implementation of the Deque interface. It is also referred to as Array Double… Read More
Vector is similar to arrays but is growable also, or we can say no fixed size is required. Previously vector was a part of legacy… Read More
ArrayList is a part of collection framework and is present in java.util package. It provides us with dynamic arrays in Java. Though, it may be… Read More
TreeSet is one of the most important implementations of the SortedSet interface in Java that uses a Tree for storage. The ordering of the elements… Read More
HashMap in java is a class that is a part of the java collection. It implements the Map interface of java. It stores the data… Read More