Self-organizing version of DCons using given re-ordering function.
The list will only be re-ordered upon execution of:
nth()
setNth()
setTail()
find()
findWith()
Reference:
Optional
Protected
Implementation of IReducible.$reduce
Rest
use DCons.prepend
Implementation of ISeqable.seq
Shuffles list by probabilistically moving cells to head or tail positions.
Supports configurable iterations and custom PRNG via IRandom (default: SYSTEM).
IRandom
SYSTEM
Default iterations: ceil(3/2 * log2(n))
ceil(3/2 * log2(n))
Merge sort implementation based on Simon Tatham's algorithm: https://www.chiark.greenend.org.uk/~sgtatham/algorithms/listsort.html
Uses compare() as default comparator.
compare()
Generated using TypeDoc
Self-organizing version of DCons using given re-ordering function.
Remarks
The list will only be re-ordered upon execution of:
nth()
setNth()
setTail()
find()
findWith()
Reference: