title: Java: split array list into chunks where objects have an equal attribute value
body: <p>I have an ArrayList list of objects, say Person</p>
  
  <p>Let's say Person has a boolean attribute of 'eligible'.</p>
  
  <p>I'd like to get a list of index pairs (i,j), such that list.sublist(i,j) has Persons with equal values of eligible. I don't want to modify the list.</p>
  
  <p>Is there an easy way to do this in Java?</p>
  
  <p>Thanks</p>