Unix MCQ Answers. Get all of the validated answers for the unix mcq. Ideal for quick and fast review or getting ready for the actual test. if you have short time then you are on right place.
Unix MCQ Answers
This is the unix mcq with 100% correct answers:
Q1. For running a Unix command within awk, we’ve to use ____ function.
- split
- system
- substr
- length
Q2. To extract specific columns from a file ____ command is used.
- cut
- pr
- head
- tail
Q3. Which of the following cannot be performed by cat command?
- appending files
- deleting files
- creating files
- displaying files
Q4. What is the default delimiter used by the cut command for cutting fields?
- underscore
- space
- tab
- double tab
Q5. Which of the following is not an internal command used by mailx?
- d
- N
- a
- q
Q6. Which of the following is not true about Unix?
- UNIX was not written in ‘C’ language
- Linux is also known as a version of UNIX
- A user can run multiple programs at the same time; hence UNIX is called a multitasking environment
- Many people can use a UNIX based computer at the same time; hence UNIX is called as a multiuser system
Q7. Which editor is used by the Unix system to edit files?
- word
- notepad++
- vi
- notepad
Q8. Which of the following is not a part of all the versions of Unix?
- System Calls
- Graphical user interface
- Kernel and Shell
- Commands and utilities
Q9. Which part of the Unix operating system interacts with the hardware?
- Application program
- Vi editor
- Shell
- Kernel
Q10. Which command is used to display the documentation of commands in Unix?
- man
- whatis
- help
- search
Q11. Which Unix command is used for changing the current directory?
- pwd
- rm
- cd
- cp
Q12. Which command is used for printing the current working directory?
- dir
- HOME
- cd
- pwd
Q13. Which command is used for listing files in a directory?
- list
- ls
- wc
- ps
Q14. Which command is used by the user to change their login password in Unix?
- cp
- man
- reset
- passwd
Q15. Which command is used for displaying the contents of a file in Unix?
- mkdir
- cat
- rm
- cp
Q16. Which command is used to compress files?
- gzip
- gunzip
- comm
- cmp
Q17. Which command is used for displaying the beginning of a file in Unix?
- lp
- begin
- pr
- head
Q18. Which symbol is used with the tail command to print the file from the selected line?
- %%
- ^
- +
- –
Q19. Which command is used to delete all files in a directory?
- del *
- rm *
- mv *
- rmdir *
Q20. echo command is used for _________
- displaying diagnostic messages
- displaying date and time
- displaying errors
- displaying operating system details
Q21. What is the function of cp command in Unix?
- delete a given file
- change the directory
- list all the available files in the current directory
- cp is a command used for copying files and directories
Q22. Which command is used for removing/deleting files in Unix?
- rm
- mv
- rmdir
- del
Q23. Which command is used for renaming files in Unix?
- rename
- move
- mv
- cp
Q24. Which command is used for comparing two files?
- comp
- cmp
- comm
- diff
Q25. Which Unix command is used for counting words, lines, and characters in a file?
- wc
- man
- count
- diff
Q26. In UNIX, which command is used to change the permissions of a file?
- chown
- chgrp
- chmod
- ch
Q27. Which symbol is used to change permissions for hidden files in Unix?
- *
- $
- &
- .
Q28. Which command is used for saving and quitting the vi editor simultaneously?
- ‘:x’
- :f
- :q
- :w
Q29. How can we escape to the UNIX shell without quitting vi editor?
- using ‘:sh’ command and using ctrl-Z
- using ‘:sh’ command
- using ctrl-Z
- using ctrl-D
Q30. For creating and removing directories, which of the following system calls are used?
- mkdir and rmdir
- rmdir and chown
- chdir and chown
- mkdir and chdir
Q31. Which of the following files are known as special files in Unix?
- /dev/null
- sample.txt
- /dev/null and /dev/tty
- /dev/tty
Q32. What is the output of the following Unix command?
- size of each .c file
- total size of .c files
- erroneous
- undefined
Q33. In Unix, for what purpose bc command is used?
- for copying files
- as a process table viewer
- as an editor
- as a calculato
Q34. Which process is immediately set up by the kernel when we log on to a Unix system?
- System
- bash
- shell
- parent
Q35. Which command shows some attributes of a process?
- HOME
- ps
- $$
- pid
Q36. Which of the following system call is used for creating a new process in Unix?
- new
- wait
- read
- fork
Q37. Which of the following command is used to create a child shell?
- sh
- env
- wait
- fork
Q38. Which Unix command is used for locating files?
- type
- loc
- find
- search
Q39. Which command is used for preparing a file for printing?
- pr
- cat
- cd
Q40. Which command is used for sorting a file on specified fields?
- pr
- cut
- tail
- sort
Q41. Which Unix command is used for locating repeated and non-repeated lines?
- cut
- paste
- uniq
- sort
Q42. Which command is used for translating characters?
- paste
- tr
- trans
- sort
Q43. Which of the following command will be used for searching “director” in emp.lst?
- grep “director” emp.lst
- grep -director emp.lst
- grep -v “director” emp.lst
- grep “director”
Q44. Which of the following command is used for searching for a pattern in one or more file(s.?
- paste
- grep
- cd
- cp
Q45. Which of the following commands is known as stream editor?
- grep
- tr
- sed
- td
Q46. What is a shell script?
- group of functions
- a file containing a series of commands
- a file containing special symbols
- group of commands
Q47. To run the script, we should make it executable first by using _____
- chmod +w
- chmod +rwx
- chmod +x
- chmod +r
Q48. Which command is used for acquiring superuser status?
- su
- pu
- super
- admn
Q49. Which command is used to find out the consumption of a specific directory?
- mem
- dv
- du
- df
Q50. Which filter apart from perl, is the most powerful?
- awk
- grep
- cut
- sed
Q51. What is Unix?
- Unix is a programming language
- Unix is a software program
- Unix is an operating system
- Unix is a text editor
Q52. The Unix shell is both _______ and _______ language.
- scripting, interpreter
- high level, low level
- interactive, responsive
- interpreter, executing
Q53. In which language UNIX is written?
- C++
- C
- JAVA
- Python
Q54. Which of the following is the first UNIX editor?
- vi
- emacs
- ex
- ed
Q55. Which of the following is not a feature of Unix?
- multiuser
- easy to use
- multitasking
- portability
Also Read: Compiler Design MCQ Answers
Note: If you have the new question on this test, please comment Question and Multiple-Choice list in form below this article. We will update answers for you in the shortest time. Thank you! We truly value your contribution to the website.








