Liking cljdoc? Tell your friends :D

merge-insertion-sort.core


binary-insertclj/s

(binary-insert n coll)
(binary-insert comp n coll)

Returns a new collection with n inserted into sorted coll so as to keep it sorted. If comp not provided, uses compare.

Returns a new collection with `n` inserted into sorted `coll` 
so as to keep it sorted. If `comp` not provided, uses compare.
sourceraw docstring

binary-search-insertion-pointclj/s

(binary-search-insertion-point n coll)
(binary-search-insertion-point comp n coll)
(binary-search-insertion-point comp n lower-bound upper-bound coll)

Return the index at which to insert n into sorted coll, using binary search. If comp not provided, uses compare.

Return the index at which to insert `n` into sorted `coll`, 
using binary search. If `comp` not provided, uses compare.
sourceraw docstring

fn->comparatorclj/s

(fn->comparator f)

Given a fn that might be boolean valued or a comparator, return a fn that is a comparator.

Given a fn that might be boolean valued or a comparator,
return a fn that is a comparator.
sourceraw docstring

insertclj/s

(insert coll n i)

Returns a new collection with n inserted at index i into coll.

Returns a new collection with `n` inserted at index `i` into `coll`.
sourceraw docstring

jacobsthalclj/s

(jacobsthal n)

Return the nth Jacobsthal number (0-indexed)

Return the nth Jacobsthal number (0-indexed)
sourceraw docstring

pending-element-orderclj/s

(pending-element-order n)

Indexes to insert bs at, given n to insert (0-indexed)

Indexes to insert `b`s at, given `n` to insert (0-indexed)
sourceraw docstring

sortclj/s

(sort coll)
(sort comp coll)

Returns a sorted sequence of the items in coll, using the merge-insertion sorting algorithm.
If comp not provided, uses compare.

Returns a sorted sequence of the items in coll, using the merge-insertion sorting algorithm.  
If `comp` not provided, uses compare.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close