Assessment: The Shell.

Oct 2, 2014 • Andy Teucher
**1. The pipe ( ) operator in the shell…**

a) Separates a shell command from a list of optional arguments for that command.
b) Redirects the output of the command on the left-hand side of the pipe as input to a command specified on the right-hand side of the pipe.
c) Redirects the output of the command on the left-hand side of the pipe as input to a file specified on the right-hand side of the pipe.
d) Instructs the shell to print the output to the screen.

2. You are working in a directory with several .csv files. Rearrange the following commands, flags, and other arguments to find the file with the most lines:

Commands

  • head
  • sort
  • wc
  • tail
  • (as many as you need)

Flags and arguments

  • -2
  • -l
  • -n
  • *.csv
  • -1