×

Team MAST's video: Java Interview Series - 2 Difference between Hashmap and HashTable Team MAST

@Java Interview Series - 2 | Difference between Hashmap and HashTable | Team MAST
You will learn 5 differences between Hashmap and HashTable. HashMap and Hashtable both are used to store data in key and value form. Both are using hashing technique to store unique keys. This question is generally asked in java intereview to check whether candidate understand correct usage of collection classes and has knowledge of alternative solutions. Major questionis, When to use HashMap and Hashtable? 1. Single Threaded Application HashMap should be preferred over Hashtable for the non-threaded applications. In simple words , use HashMap in unsynchronized or single threaded applications . 2. Multi Threaded Application We should avoid using Hashtable, as the class is now obsolete in latest Jdk 1.8 . Oracle has provided a better replacement of Hashtable named ConcurrentHashMap. For multithreaded application prefer ConcurrentHashMap instead of Hashtable. Also Watch Java Collections API Video Series here : https://www.youtube.com/watch?v=QqqLhOuv_v4&list=PLqrRs5DI6ahPtQUFI2YaMaMlmA83iOyw4

11

4
Team MAST
Subscribers
27.1K
Total Post
123
Total Views
361.6K
Avg. Views
7.2K
View Profile
This video was published on 2016-05-21 17:00:01 GMT by @Team-MAST on Youtube. Team MAST has total 27.1K subscribers on Youtube and has a total of 123 video.This video has received 11 Likes which are lower than the average likes that Team MAST gets . @Team-MAST receives an average views of 7.2K per video on Youtube.This video has received 4 comments which are lower than the average comments that Team MAST gets . Overall the views for this video was lower than the average for the profile.

Other post by @Team MAST