Why Hashtable doesn't allow null key/value while Hashmap does.

Why Hashtable doesn't allow null key/value while Hashmap does.
Why Hashtable doesn't allow null key/value while Hashmap does.In this post we will learn why Hashtable doesn't allow null key and null value while HashMap does.How Hashtable and HashMap compute bucket Index. Before checking this post, I would recommend...

Create Linked Lists of all the nodes at each depth in a binary tree.

Create Linked Lists of all the nodes at each depth in a binary tree.
Create Linked Lists of all the nodes at each depth in a binary tree.Creating linked list of Nodes at same level in a Binary tree is same as printing nodes at each level of a Binary tree with only difference is to collect the Nodes in a list for each...

Find Inorder successor of a Node in BST

Find Inorder successor of a Node in BST
Find Inorder successor of a Node in BST.Inorder traversal of a Binary Tree reads a Left most element first then a middle or root element and at last the right most element, so when we say successor of a Node, you have to return the next element of the...

Min Heap and Max Heap in Java

Min Heap and Max Heap in Java
Min Heap and Max Heap in Java.In this post we will see what is Min Heap, Max Heap, the operation it supports and the time and space complexity of each operation.Complete Binary Tree. Min Heap and Max Heap uses the concept of Complete Binary Tree.A...

Find the angle between the hour and minute hands in Java

Find the angle between the hour and minute hands in Java
Find the angle between the hour and minute hands on an analog clock.Given the time, calculate the smaller angle between the hour and minute hands on an analog clock in Java.Java Program to find angle between hour and minute hand. In 60 mins, clock...

Visitor Design Pattern real world example in Java

Visitor Design Pattern real world example in Java
Visitor Design Pattern real world example in JavaIn this post we will see when to use visitor design pattern and the real life example of visitor design pattern in Java.Scenario for understanding Visitor Design Pattern. Consider a scenario below,You...

Swagger OpenAPI REST Java Example using Guice and Jersey

Swagger OpenAPI REST Java Example using Guice and Jersey
Swagger OpenAPI REST API Java Example using Guice and JerseyIn this post we will see how to integrate Swagger in Guice and Jersey to dynamically generate OpenAPI REST endpoint documentation.Sample project uses below libraries,1. Google Guice2. Jersey2....

Create Docker Image of Spring Boot Microservices using Fabric8 maven plugin.

Create Docker Image of Spring Boot Microservices using Fabric8 maven plugin.
Create Docker Image of Spring Boot Microservices using Fabric8 maven plugin.In this post we will see how to create a Docker image of Spring Boot Microservice using Fabric8 maven plugin.Steps,1. First we will create a Spring Boot Microservice with some...
Page 1 of 2812345...28Next »