Sort the Words
Print the words in lexicographic (dictionary) order, separated by single spaces.
Input: one line with words separated by single spaces.
Output: the words sorted lexicographically.
Constraints:
- 1 to 200 words of lowercase letters
Sample Tests
Input 1
banana apple cherry
Output 1
apple banana cherry
Input 2
b a
Output 2
a b
Discussion (opens after you solve — no spoilers before)
No comments yet.