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

Content added Content deleted
Line 416: Line 416:
⟳ c:l_list ¦ Result.append_character (c) ⟲ -- Populate it with the sorted chars
⟳ c:l_list ¦ Result.append_character (c) ⟲ -- Populate it with the sorted chars
Result.adjust -- Remove the leading white space
Result.adjust -- Remove the leading white space
ensure
no_spaces: ∀ c:Result ¦ c /= ' ' -- All spaces removed.
has_all: ∀ c:Result ¦ s.has (c) -- All non-space chars present.
end
end