Friday, March 13, 2015

Difference Between HashMap and Treemap




           
HashMap
TreeMap
HashMap can contain one null value
Where as tree map does not contain null value throws runtime exception
HashMap does not maintain insertion order
Where as tree map maintains ascending order.

No comments:

Post a Comment