4.17.11
3.10.1
2.4.2
1.3.1
_.sortedLastIndex(array, value)
This method is like _.sortedIndex
except that it returns the highest
index at which value
should be inserted into array
in order to
maintain its sort order.
Since
3.0.0
Arguments
argument
array
value
type
Array
*
description
The sorted array to inspect.
The value to evaluate.
Returns
(array)
Example
_.sortedLastIndex([4, 5, 5, 5, 6], 5);
// => 4
_.sortedLastIndex([4, 5, 5, 5, 6], 5);
// => 4