Unix MCQ of Computer Science SET-4 with Answers free PDF Download

We have provide here is the list of Unix MCQs for Computer Engineering preparation competitive exams. Each question has four options followed by the right answer.

MCQ Questions for Unix of Computer Science with Answers

Q1. The command used to remove the directory is;

(i) rmdir
(ii) rd
(iii) remove
(iv) rdir

(i) rmdir

Q2. The command used to compare the files is known as

(i) comp
(ii) cmp
(iii) do
(iv) ccp

(ii) cmp

Q3. Which symbol will be used with grep command to match the pattern pat at the end of a line?

(i) ^pat
(ii) $pat
(iii) pat$
(iv) pat^

(iii) pat$

Q4. Which of the following commands is used to view your file 24 lines at a time?

(i) pg
(ii) cat
(iii) lp
(iv) /p

(i) pg

Q5. Which of the following special shell variables is used to process number of the last background job?

(i) $!
(ii) $#
(iii) $0
(iv) $*

(i) $!

Q6. Which option will be used with touch command to change the access time?

(i) -a
(ii) -b
(iii) -t
(iv) -h

(i) -a

Q7. Which of the following commands is used to display your working directory?

(i) dir
(ii) prompt $p$g
(iii) pwd
(iv) path

(iii) pwd

Q8. Which of the following shell’s wildcards are used to match any number of characters including none?

(i) [ijk]
(ii) [!ijk]
(iii) ?
(iv) *

(iv) *

Q9. Which of the following commands is used to change the working directory?

(i) cd
(ii) changedir
(iii) chdir
(iv) cdir

(i) cd

Q10. Which command will be used with vi editor to insert text to left of cursor?

(i) s
(ii) S
(iii) a
(iv) i

(iv) i

Q11. Which command is used to list all the files with extension .lst?

(i) ls -l .lst (ii) ls lst
(iii) ls .
(iv) ls *[lst]

(i) ls -l *.lst

Q12. Which command will be used with vi editor to append text at end of line?

(i) A
(ii) a
(iii) i
(iv) I

(i) A

Q13. The second set of the three permissions (r-) indicates that

(i) group has read permission only
(ii) other has read permission only
(iii) owner has read permission only
(iv) group has write permission only

(i) group has read permission only

Q14. The first set of the three permissions (rw) pertains to the owner of the file, indicating that the owner has

(i) executable permission only
(ii) write and executable permissions
(iii) both read and executable permissions.
(iv) both read and write permissions

(iv) both read and write permissions

Q15. Which of the following commands is used to count the total number of lines, words, and characters contained in a file.

(i) count p
(ii) wc
(iii) wcount
(iv) countw

(ii) wc

Q16. Which of the following commands is used to list contents of directories?

(i) ls
(ii) lp
(iii) dir
(iv) tar

(i) ls

Q17. Which of the following commands is not the vi Input mode command?

(i) rch
(ii) R
(iii) S
(iv) j

(iv) j

Q18. Which of the following keys is used to delete the character beneath the cursor?

(i) x
(ii) X
(iii) dd
(iv) D

(i) x

Q19. Which command is used to make all files and sub-directories in the directory (progs) executable by all users?

(i) chmod -R a+x progs
(ii) chmod -R 222 progs
(iii) chmod -1 a+x progs
(iv) chmod -x a+x progs

(i) chmod -R a+x progs

Q20. Which of the following commands is used to save the output of the who command in a file named user.lst, as well as display it?

(i) who | tee user.lst
(ii) who > user.lst
(iii) who >> user.lst
(iv) who < user.lste

(i) who | tee user.lst

We hope the given Computer Engineering MCQ Questions for Unix with Answers PDF Free Download will help you. If you have any queries regarding Unix MCQs Multiple Choice Questions with Answers, drop a comment below and we will get back to you soons.

Leave a Comment