title: Find indexes of repeated elements in an array (Python, NumPy)
body: <p>Assume, I have a NumPy-array of integers, as:</p>
  
  <pre><code>[34,2,3,22,22,22,22,22,22,18,90,5,-55,-19,22,6,6,6,6,6,6,6,6,23,53,1,5,-42,82]
  </code></pre>
  
  <p>I want to find the start and end indices of the array, where a value is more than x-times (say 5-times) repeated. So in the case above, it is the value 22 and 6. Start index of the repeated 22 is 3 and end-index is 8. Same for the repeatening 6.
  Is there a special tool in Python that is helpful? 
  Otherwise, I would loop through the array index for index and compare the actual value with the previous. </p>
  
  <p>Regards.</p>