1.
Which
of these is not a common UNIX shell discussed in class?
a. bash
b. sh
c. fresh
d. ksh
2.
In
ksh,
what is the difference between the expressions VAR and $VAR?
a.
VAR refers to a variable name and $VAR to its value
b.
VAR refers to a variable value and $VAR to its name
c.
VAR refers to an integer variable and $VAR to a string variable
d.
both
expressions refer to the same thing
Answer:
a
3.
Which
of these expressions shows the proper way to add the directory /usr/bin to your path?
a. PATH+=/usr/bin
b. PATH=/usr/bin
c. $PATH:/usr/bin
d. PATH=$PATH:/usr/bin
Answer:
d
4.
What
is the effect of the command alias up2=”cd ../..”?
a.
typing
“cd ../..” at a shell prompt causes the shell to print “up2”
b.
typing
“up2” at a shell prompt takes you up two levels in the directory tree
c.
you
immediately go up two levels in the directory tree and a new alias is created
d.
an
error message is printed
Answer:
b
5.
Which
of the following is not a benefit of the fact that many UNIX commands
operate on plain ASCII text files?
a.
the
same file can be used by many programs
b.
output
to the terminal and to files can be done in the same way
c.
most
current UNIX installations have a graphical user interface
d.
these
commands can be used as filters for the output of other commands
Answer:
c