Apache Commons Collections OrderedMap 1. Overview The Apache Commons Collections library provides useful classes that complement the Java Collections Framework. In this article, we will review the interface OrderedMap, which extends java.util.Map. 2. Maven Dependency The first thing we need to do is to add the Maven dependency in our… Continue Reading apache-commons-ordered-map

Differences Between HashMap and Hashtable 1. Overview In this short tutorial, we are going to focus on the core differences between the Hashtable and the HashMap. 2. Hashtable and HashMap in Java Hashtable and HashMap are quite similar – both are collections that implement the Map interface. Also, the put(), get(), remove(), and containsKey() methods provide constant-time… Continue Reading hashmap-hashtable-differences

Time Complexity of Java Collections 1. Overview In this tutorial, we’ll talk about the performance of different collections from the Java Collection API. When we talk about collections, we usually think about the List, Map, and Set data structures and their common implementations. First of all, we’ll look at Big-O complexity insights… Continue Reading java-collections-complexity