How to find the position of an item of a list in python?
<p>I have two lists. The first list has a specific length and the second list has unstable length. I want to assign the items from two lists.
I use <code>colour_index = sel_pos%(len(colours))</code>. The sel_pos is the item's position from the unstable list.
How to find the position every time?</p>

<pre><code>colour_index = selections.index(txt)%(len(colours))
</code></pre>

python list colors position variable-length-array