unary function that returns true for some element
the input range to search
which index to start searching from
some!size_t or none if no element was found
import optional: some, none; assert([1, 2, 3, 4].indexWhere!(a => a % 2 == 0) == some(1)); assert([1, 2, 3, 4].indexWhere!(a => a == 5) == none); assert([1, 2, 3, 4].indexWhere!(a => a % 2 == 0)(2) == some(3));
0.0.1
Returns optional index of the first element predicate returns true for.