Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to implement Hash Map?

Answer Posted / rice


HashMap is a class that implements Map interface.

HashMap underlined data structure is Hash table.

If we want to describe the group of objects as key ,value
pairs then we go for HashMap class.

key are not duplicated but value can be any thing.

null insertion is possible.

insertion order is not preserved.

HashMap hm=new HashMap();
hm.put(1, "rice");
hm.put(3, "rice");
hm.put(2, "shine");
System.out.println(hm);

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Describe life cycle of thread?

968


Is jar an executable?

859


What is the java virtual machine (jvm)?

1074


What is entitymanager in jpa?

863


Is openjdk the same as jdk?

902


Do I need jdk or jre?

838


Differences between intermediate operations and terminal operations of java 8’s stream api?

1055


How does jpa repository work?

911


What does persist mean in java?

971


What are jpa annotations?

903


What happens when you omit a brace or misspell one of the words, like public or

882


What is the difference between ec2 and lambda?

882


What is xml file in java?

914


What are anonymous methods and lambda expression?

827


What are the rules regarding quotation marks?

941