title: Python loop index of key, value for-loop when using items()
body: <p>Im looping though a dictionary using </p>
  
  <pre><code>for key, value in mydict.items():
  </code></pre>
  
  <p>And I wondered if theres some pythonic way to also access the loop index / iteration number. Access the index while still maintaining access to the key value information.</p>
  
  <pre><code>for key, value, index in mydict.items():
  </code></pre>
  
  <p>its is because I need to detect the first time the loop runs. So inside I can have something like</p>
  
  <pre><code>if index != 1:
  </code></pre>