要素のソートされたセットを返します。
構文は次のとおりです。
(sorted-set setofelements)
パラメータ-「setofelements」は、ソートする必要がある要素のセットです。
戻り値-要素のソートされたセット。
以下は、Clojureのソート済みセットの例です。
(ns clojure.examples.example (:gen-class)) (defn example [] (println (sorted-set 3 2 1))) (example)
上記のコードは次の出力を生成します。
#{1,2,3}