Corrected error in prefixBinarySearch

There were an obvious mistake in the calculation of the middle for the binary search. (stopIndex + stopIndex) / 2 will evualuate  to stopIndex and not to the arithmetic middle as intended.
Merge pull request #2858 from TwoStone/patch-1

Corrected error in prefixBinarySearch