title: Is there a Java equivalent of Python's 'enumerate' function?
body: <p>In Python, the <a href="http://docs.python.org/library/functions.html#enumerate" rel="noreferrer"><code>enumerate</code></a> function allows you to iterate over a sequence of (index, value) pairs. For example:</p>
  
  <pre><code>&gt;&gt;&gt; numbers = ["zero", "one", "two"]
  &gt;&gt;&gt; for i, s in enumerate(numbers):
  ...     print i, s
  ... 
  0 zero
  1 one
  2 two
  </code></pre>
  
  <p>Is there any way of doing this in Java? </p>