1

I'm looking for instances in the core python 2.x that uses the binary search algorithm. Do you have any quick pointers where to look ?

2

1 Answer 1

2

The bisect module uses a binary search. Here's a link to the source code: http://hg.python.org/cpython/file/2.7/Lib/bisect.py

Most of the rest of the Python core uses either hash tables or linear searches.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.