Sort the letters of string in alphabetical order: Difference between revisions

Content added Content deleted
(→‎{{header|J}}: include definitions)
Line 548: Line 548:
{{a.#~<:#/.~a.,y}} text1
{{a.#~<:#/.~a.,y}} text1
"".TTaaabbccdeeeeeeeeeeeeeefghhhhhiijklllmnnnnooooppqrrrrssssttttttuuuvvwxyyz</lang>
"".TTaaabbccdeeeeeeeeeeeeeefghhhhhiijklllmnnnnooooppqrrrrssssttttttuuuvvwxyyz</lang>

(Since there's no comparison between pairs in bucket sort, performance here is O(n) rather than O(n log n).)


=={{header|jq}}==
=={{header|jq}}==