2 ms·
A project I worked on needed more than just the value (or lack of value) from a sorted array---it also needed the index where the item would have been had it be
by spc476 16y ago
A project I worked on needed more than just the value (or lack of value) from a sorted array---it also needed the index where the item would have been had it been in the array. The standard binary search in the language I was using didn't return that information.
Sometimes, the requirements exceed what the standard stuff gives you.