Sort Into Folders
Move every file in this folder into a folder named after its ending: a.txt goes to txt/a.txt, pic.png to png/pic.png. Make the folders that are needed. Some names have spaces.
Example 1
a.txt
1
b.txt
2
pic.png
3
ends as
== ./png/pic.png 3 == ./txt/a.txt 1 == ./txt/b.txt 2
Constraints
- Up to 8 files, each with one dot in its name
- No folders inside at the start
Write it in your browser, against the clock. The model script, with a note on each command it uses, comes after.
More Bash problems
- TODOs per FileHard
- The Biggest FileHard
- Totals per GroupHard
- Word Count TableHard
- Count the LinesBeginner
- Count the WordsBeginner
- First Three LinesBeginner
- Hello, NameBeginner