Unix / Linux Online Quiz



Following quiz provides Multiple Choice Questions (MCQs) related to Unix Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : C

Explanation

Dot dot (..) represents parent directory and Dot (.) represents current working directory.

Q 2 - Which of the following is correct to create an alias name for 'ls' as 'list'?

A - alias list=”ls”

B - alias list “ls”

C - alias “list” as “ls”

D - alias “ls” as “list”

Answer : A

Explanation

Syntax is alias alias-name=”command”.

Q 3 - Which is following key moves the cursor to the end of the line in vi editor?

A - 0

B - $

C - {

D - }

Answer : B

Explanation

Q 4 - Option to mention field separator for the command ‘cut’ is __

A - -f

B - -c

C - -d

D - \0

Answer : C

Explanation

–d means as delimiter, acts as field separator.

Q 5 - Choose the correct usage of ‘cd’ to move into parent directory.

A - cd

B - cd..

C - cd/

D - None of the above

Answer : D

Explanation

cd ..(space between cd and ..) is correct instead of cd..

Q 6 - Which command can be used to create links for file/directory?

A - lk

B - ln

C - new

D - makelink

Answer : B

Explanation

ln is the command used to create hard/soft link for a file and hard link for a directory.

Q 7 - Which command can give first found difference between two file after comparing?

A - diff

B - cmp

C - Common

D - None of the above.

Answer : B

Explanation

cmp command is used in general to find for equal files.

Q 8 - Which command from the following can create a file if doesn’t exist?

A - tee

B - make

C - makefile

D - touch

Answer : D

Explanation

touch can update access and modification time apart from creating an empty file.

Q 9 - Which command can introduce clock delay?

A - sleep

B - wait

C - suspend

D - delay

Answer : A

Explanation

Q 10 - The default number of link count for a newly created file is __

A - 0

B - 1

C - 2

D - 4

Answer : B

Explanation

unix_questions_answers.htm
Advertisements