← Linux and the Command Line Lesson 11 of 51 · 5 XP

Warm-up: sort warm-up

Theory and problem statement

Machine translation, not yet reviewed by a native speaker.

A script gets text as its input — just as if it were typed on the keyboard. The sort command reads the lines and prints them in alphabetical order:

sort

The input cat, apple, banana becomes apple, banana, cat.

Task. Print the input lines sorted alphabetically.

Sign up for free to solve this task right in your browser: code editor, running, test checks and hints.