title: HashMap uses LinkedList internally
body: <pre><code>public V get(Object key) {
  if (key == null)
      return getForNullKey();
      int hash = hash(key.hashCode());
      for (Entry&lt;K,V&gt; e = table[indexFor(hash, table.length)];
           e != null;
           e = e.next) {
          Object k;
          if (e.hash == hash &amp;&amp; ((k = e.key) == key || key.equals(k)))
              return e.value;
      }
      return null;
  }
  </code></pre>
  
  <p>What I knew is, if you want to get a object from <code>HashMap</code>, first of all it searches the hash bucket based on hashcode/hash value and then iterates through the <code>LinkedList</code> in that hashbucket(suppose the diff objects have same hash code, thus in the same hash bucket).</p>
  
  <p>But after looking at the code above, I am not able to understand when it iterates through the LinekedList(and where is the LinkedList)</p>