Lab Assignment 3
Lab Assignment 3
Module 2 :
1. Start script again and append to the existing output file of step 14
2. Explain the task of the following commands-chaining :
sort < files.txt > temp ; head -5 < temp ; rm temp
(Note that files.txt contains a detailed listing of your home directory; (ls -l ~ > files.txt))
3. Write down the command, so that you transform it to a piping that performs the same task.
4. Write down the piping, so that you replace files.txt with ls -l ~ (i.e., original command that we
redirected its output to files.txt). Is it workable ? Justify ?
5. Re-write the command, so that you can perform a correct piping and append the output to
files.txt.
6. Exit out of script.