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?

Answers were Sorted based on User's Feedback



what is the difference between HashMap And HashTable?..

Answer / ravikiran

HashMap allows one null key and multiple null values
HashTable doesnn't allow nulls
HashMap is not synchronized
hashtable is synchronized

Is This Answer Correct ?    13 Yes 0 No

what is the difference between HashMap And HashTable?..

Answer / stalin

The HashMap class is roughly equivalent to Hashtable, except
that it is unsynchronized and permits nulls. (HashMap allows
null values as key and value whereas Hashtable doesnt
allow). HashMap does not guarantee that the order of the map
will remain constant over time. HashMap is unsynchronized
and Hashtable is synchronized

Is This Answer Correct ?    8 Yes 0 No

what is the difference between HashMap And HashTable?..

Answer / guest

HashMap is a nonsyncronized and HashTable is a
syncronized.

Is This Answer Correct ?    7 Yes 0 No

what is the difference between HashMap And HashTable?..

Answer / venkateswarlu

HashMap :
->It is a key,value pair.
->key are not duplicated but values can be duplicated.
->Null key is possible.
->It is not Synchronized by default.

Hashtable:
->It is also key,value pair but both are Strings only.
-> Keys are not duplicated but values can be duplicated.
->Null insertion is not possible of both(key and value).
->It is Synchronized by default.

Is This Answer Correct ?    0 Yes 0 No

what is the difference between HashMap And HashTable?..

Answer / raghu

HashMap only one null key and multiple values. Hashtable
doesn't allow null keys and values, it throws
NullPointerException. Both are not guarantee order. HashMap
is unsyncronized, whereas Hashtable is not.

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More Core Java Interview Questions

Can constructor be synchronized?

0 Answers  


What is Recursion Function?

0 Answers   iNautix,


How many bytes is string in java?

0 Answers  


What is difference between Heap and Stack Memory?

0 Answers  


What is the difference between @before and @beforeclass annotation?

0 Answers  


What are desktop procedures?

0 Answers  


Which sorting is used in arrays sort in java?

0 Answers  


How to find the length and capacity of a string buffer ?

2 Answers  


Can we add two byte variables and assign the result to a byte variable ? b=b1+b2 where b,b1,b2 are byte types

4 Answers   TCS,


Write an algorithm for quick sort?

0 Answers   Virtusa,


What is the difference between multitasking and multithreading in Java

0 Answers   Sans Pareil IT Services,


What is unsigned char?

0 Answers  


Categories