What is the difference between the HashMap and Map objects in Java?

后端 未结 13 1273
无人及你
无人及你 2020-11-22 17:07

What is the difference between the following maps I create (in another question, people answered using them seemingly interchangeably and I\'m wondering if/how they are diff

13条回答
  •  时光取名叫无心
    2020-11-22 17:32

    Map is the Interface and Hashmap is the class that implements that.

    So in this implementation you create the same objects

提交回复
热议问题