Java, Spring, Microservices, Interview, Coding.
in HashSet and then came the statement that HashSet internally uses HashMap to store objects. These two statements may sound contradictory as HashMap stores (key, value) pair so let’s see how these these two contradictory statements hold true. Actually from add method of HashSet class put() method