Question 1
What is the output of the following bash script?

The IIT Madras BS System Commands (System Commands) Quiz 2 paper sat on 10 Jul 2022, in the May 2022 term: 18 questions for 100 marks in 120 minutes. Every question is below with its answer. Take it as a timed mock test to be marked, or read it through first.
What is the output of the following bash script?
Correct answer: 4321
What is the expected output of the following command.
Gives the total number of directories in the current working directory.
Gives the total number of directories with space in their name in the current working directory.
Gives the total number of files with space in their name in the current working directory.
Gives the total number of directories with a dot in their name in the current working directory.
Correct answer
Gives the total number of directories with space in their name in the current working directory.
Correct answer
Correct answer
0
53
45
1
45.53
Correct answer
45
Prints the line having only three digits.
Prints the line having at least three digits.
Prints the line having three consecutive digits.
Prints the line having at most two consecutive digits.
Correct answer
Prints the line having three consecutive digits.
Correct answer
What will the below command print?
Second occurrences of duplicate lines.
Distinct lines in the alphabetically sorted order.
Distinct lines in the order of first occurrence.
The lines that are present more than once.
Correct answer
Distinct lines in the order of first occurrence.
Here is a part of information from AWK manual,
Correct answer
Correct answers
Correct answers
Correct answers
The following bash script performs some operation. This script is run with some command line arguments. The command line argument values contains only alphanumeric characters.
Which of the following bash scripts is an will give the same output as the above script?
Correct answers
Correct answers
Consider the AWK script and answer the given subquestions
Select all the correct statement(s) with respect to the given AWK script.
Correct answers
Consider the AWK script and answer the given subquestions
Select the output of the AWK script on the input given below.
Correct answer
Based on the above data, answer the given subquestions
Correct answers
Based on the above data, answer the given subquestions
Correct answer