title: Excel: is there a function that returns a range for satisfying the matching condition?
body: <p>Given a value compare with the subsequent rows (on the same column) and return the range upto the row where the value changes for the first time.</p>
  
  <pre><code>Example:
     A
  1  cat
  2  cat
  3  cat
  4  dog
  5  cat
  </code></pre>
  
  <p>The range to be returned is A1:A3.</p>