Home > MCQs > IT & Programming > Unix Shell Script MCQs

Unix Shell Script MCQ

Unix Shell Script Quick Quiz

Question 1 of 10
  • Which of the following is not a shell keyword?

    Answer & Explanation

    Correct Answer: ls

    Note: This Question is unanswered, help us to find answer for this one

  • The expression expr -7 % 2 evaluates to:

    Answer & Explanation

    Correct Answer: -1

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following is/are allowed in an arithmetic statement involving expr command?

    Answer & Explanation

    Correct Answer: 3-5

    Note: This Question is unanswered, help us to find answer for this one

  • The exit statement is used in a loop to:

    Answer & Explanation

    Correct Answer: terminate the execution of a script.

    Note: This Question is unanswered, help us to find answer for this one

  • A shell script is executed by:

    Answer & Explanation

    Correct Answer: an interpreter.

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following is true about the "continue" statement?

    Answer & Explanation

    Correct Answer: It continues the control to the beginning of the loop, bypassing the statements below it, inside the loop.

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following assignments is illegal?

    Answer & Explanation

    Correct Answer: c=`1972`

    Note: This Question is unanswered, help us to find answer for this one

  • The expression expr -2 % 7 evaluates to:

    Answer & Explanation

    Correct Answer: -2

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following loops is invalid?

    Answer & Explanation

    Correct Answer: while $

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following shows the correct precedence order of operators used in a shell? Operators on left side of comma have higher precedence than those on the right side of comma.

    Answer & Explanation

    Correct Answer: ( ) , ** , * or / , + or -

    Note: This Question is unanswered, help us to find answer for this one

  • Unix Shell Script Quick Quiz

    battery

    Poor Results!

    You need a lot of improvement.

    Just don't give up!

    Correct Answers: 0/10

    Start Practicing with our MCQs given below.