what is the difference between HashMap and Hashtable

Answer Posted / green

HashTable is a Legacy Class,where as HashMap is not.
HashTable is Syncronized,where as HashMap is not.
HashTable does not allow any null keys nad values, HashMap
allows one null key and 'n' number null values.
comparatively HashMap is faster then HashTable

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is natural ordering in java?

750


What is main in java?

810


Can we print null in java?

803


What is a java object and java application?

820


Which package has light weight components?

781


what is singleton in java?

820


Explain the use of sublass in a java program?

789


What are the restrictions imposed by a Security Manager on Applets?.

2343


What is a method signature java?

835


What is the synonym of string?

802


Explain about wait() method?

803


What is string args [] in java?

787


What are the advantages of packages in java?

964


Is alive method in java?

735


Is string a data type in java?

823