static public int countRangesThatCollideZone(List<Bounds> ranges,List<Bounds> zoneRanges){
  int overallEOAA=0;
  Collections.sort(zoneRanges);
  for (  Bounds extractedBounds : ranges) {
    for (    Bounds expectedBounds : zoneRanges) {
      if (expectedBounds.start >= extractedBounds.end) {
        break;
      }
      if (extractedBounds.overlaps(expectedBounds)) {
        overallEOAA++;
        break;
      }
    }
  }
  return overallEOAA;
}

static public int countRangesThatCollideZone ( List < Bounds > ranges , List < Bounds > zoneRanges ) { int overallEOAA = 0 ; Collections . sort ( zoneRanges ) ; for ( Bounds extractedBounds : ranges ) { for ( Bounds expectedBounds : zoneRanges ) { if ( expectedBounds . start >= extractedBounds . end ) { break ; } if ( extractedBounds . overlaps ( expectedBounds ) ) { overallEOAA ++ ; break ; } } } return overallEOAA ; }
counts the number of checkedranges that overlaps with the zoneranges . a bounds object in checkedranges who doesn ' t overlap with zoneranges are not counted .
