will it allow to add same value in HashMap class.



will it allow to add same value in HashMap class...

Answer / Saurav Kumar

Yes, you can add the same key-value pair multiple times in a HashMap. However, if you add the same key again, the old value associated with that key will be replaced by the new value.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Programming Languages AllOther Interview Questions

Difference between debugging, running, executing of an application

1 Answers   HCL,


what are wrapper classes

2 Answers  


Corillian's product is a "Component Container." Name at least 3 component

1 Answers  


how can we implement locks in plsql?

1 Answers  


Which method protects back button to retrieve old value from previous page in Struts.

1 Answers  


Given n red balls and m blue balls and some containers, how would you distribute those balls among the containers such that the probability of picking a red ball is maximized, assuming that the user randomly chooses a container and then randomly picks a ball from that.

1 Answers   Amazon,


Write a program to create a process in UNIX

1 Answers  


Write a program to find whether a given number is prime or not.

1 Answers   Syntel, Visa,


how do i add a column dynamically in a table by using java application?

1 Answers  


A string of charaters were given. Find the highest occurance of a character and display that character. eg.: INPUT: AEGBCNAVNEETGUPTAEDAGPE

7 Answers   Nagarro,


which is the best institute for testing tools in hyderabad?

1 Answers  


how to hide prompts

1 Answers  


Categories