1.1.1 • Published 6 years ago

binary-search-async v1.1.1

Weekly downloads
3
License
CC0-1.0
Repository
github
Last release
6 years ago

binary-search

adapted from darkskyapp's binary-search

example

var search = require('binary-search-async')

search(function get (i, cb) {
  asyncLookup(i, cb)
}, target, compare, lo, hi, cb)

All arguments are mandatory. this assumes you are using integer indexes.

note: hi is the highest index, not the length! highest index is length - 1!

License

To the extent possible by law, The Dark Sky Company, LLC has waived all copyright and related or neighboring rights to this library.