1.

The first line in any shell script begins with a _____(a) &(b) !(c) $(d) #I got this question in quiz.Question is taken from Shell Programming using read Command and Command Line Arguments topic in portion Essential Shell Programming of Unix

Answer» CORRECT answer is (d) #

For EXPLANATION I would say: When the comment character (#) is PLACED anywhere in a line; the shell ignores all characters on its right. However, this rule doesn’t apply to the first line which is the interpreter line. It always begins with #! and FOLLOWED by the pathname of the shell to be used for running the script.


Discussion

No Comment Found

Related InterviewSolutions