JanetDocsPlaygroundI'm feeling luckyGitHub sign in

sorted



    function
    boot.janet on line 854, column 1

    (sorted ind &opt before?)

    Returns a new sorted array without modifying the old one. If a 
    `before?` comparator function is provided, sorts elements using 
    that, otherwise uses `<`.


See also:sortsorted-by2 examplesSign in to add an example
Loading...
# with by function 

(sorted [1 -2 2 3 9 -10] >)  #@[9 3 2 1 -2 -10]
leobmPlayground
(sorted [1 -2 2 3 9 -10])  # @[-10 -2 1 2 3 9]
btbytesPlayground