question: int boundedIndexOf ( String string , char search , int start , int end ) { int retValue = string . indexOf ( search , start ) ; if ( retValue >= end ) { return - 1 ; } return retValue ; }
target:  Similar to String.indexOf, but allows an upper bound (this is slower in that it will still check string starting at start.