mirror of
https://github.com/carp-lang/Carp.git
synced 2024-09-11 05:25:28 +03:00
11 lines
253 B
Plaintext
11 lines
253 B
Plaintext
|
(defmodule Sort
|
||
|
(doc sort! "Perform an in-place heapsort of a given array.")
|
||
|
(defn sort! [arr]
|
||
|
(HeapSort.sort! arr))
|
||
|
|
||
|
(doc sort "Perform a heapsort in a new copy of given array.")
|
||
|
(defn sort [arr]
|
||
|
(HeapSort.sort arr))
|
||
|
)
|
||
|
|