index() of last occurrence in list in python
<p>In my for loop, I got this code:    </p>

<pre><code>start = listData.index(datum) + 1
</code></pre>

<p>and listData is: </p>

<pre><code>listData = ['H66', 'B35', 'L21', 'B35', 'H66', 'J02', 'J04', 'L21', 'J20']   
</code></pre>

<p>what I want is start = 1,2,3,4,5,6,7,9</p>

<p>but I got start = 1,2,3,2,1,6,7,3 (because index() return the index of the first occurrence? I guess?)    </p>

<p>Is there any way to index last occurrence ?         </p>