title: Erlang lists:index_of/2 function?
body: <p>I'm looking for an Erlang library function that will return the index of a particular element in a list.</p>
  <p>So, if</p>
  <pre class="lang-erlang prettyprint-override"><code>X = [10,30,50,70]
  </code></pre>
  <pre><code>lists:index_of(30, X)
  </code></pre>
  <p>would return 1, etc., just like <code>java.util.List</code>'s <code>indexOf()</code> method.</p>
  <p>Does such a method exist in the Erlang standard lib? I tried looking in the lists module but no luck. Or should I write it myself?</p>