Red Hat Certified System Administration 8



Quizz 01

Question 1

How do you stop a script to allow a user to provide input?

a. pause
b. break
c. read
d. stop

C. The read statement stops a script, which allows a user to provide input. If read is used with a variable name as its argument, the user input is stored in this variable.

Question 2

Which line stores the value of the first argument that was provided when starting a script in the variable NAME?

a. NAME = $1
b. $1 = NAME
c. NAME = $@
d. NAME=$1

D. The first argument is referred to as $1. To store $1 in a variable with the name NAME, use the command NAME=$1. Make sure that no spaces are included, which is why answer A is incorrect.

Question 3

What is missing in the following script at the position of the dots?

a. in
b. do
c. run
d. start

B. After stating the condition in a for loop, do is used to start the commands that need to be started when the condition is true.

Question 4




Question 5




Question 6









+ Correction



Eninam BAGNABANA     |         |     bagnadavid@outlook.fr     |