Question d’entretien chez Garmin

What is the difference between a Hashmap and a Treemap?

Réponse à la question d'entretien

Utilisateur anonyme

29 oct. 2014

Basic differences include: Treemaps are ordered and must consist of comparable objects. You can construct a Treemap with a comparator so that objects are ordered in a specific way. Hashmaps consist of keys that are associated with some value. They allow fast addition and deletion of objects.