Skip to content

Document spire.math.Searching #561

@denisrosset

Description

@denisrosset

The behavior of the binary search is the same as Java's Arrays.binarySearch: it either returns the index of the element, or -insertionIndex - 1.

But for the parameters, it asks for an inclusive range while Java's Arrays.binarySearch excludes the lsat index.

The code in Spire is similar to the code of the JDK, see

(This issue is mostly a reminder for myself, I'm on another branch)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions