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...

what is the difference between HashMap and Hashtable

Answer Posted / chandan

The key difference between the two is that access to the
Hashtable is synchronized on the table while access to the
HashMap isn't. You can add it, but it isn't there by default.

Another difference is that iterator in the HashMap is
fail-safe while the enumerator for the Hashtable isn't. If
you change the map while iterating, you'll know.

And, a third difference is that HashMap permits null values
in it, while Hashtable doesn't.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are checked exceptions?

1030


Explain numeric promotion?

1098


What is Major and importance difference between for and foreach loop ?

1140


What is a generic data type?

1030


What is a class reference?

1092


Why is the main method declared static?

1125


What are the methods available in a class?

1074


Why Java is not pure Object Oriented language?

1101


Can a class be declared as static?

1163


How do you sing an Applet ?

2459


Can we have more than one package statement in source file ?

1016


Does java return by reference?

999


How is java created?

936


Does a function need a return?

961


What is supplier in java?

1000