Home > Class 11 Biology > Quizzes > Unix Basics Practice Test: Handling Ordinary Files
Unix Basics Practice Test: Handling Ordinary Files
Fast practice, instant feedback. Timer auto-submits when time’s up.
Avg score: 87% Most missed: “Which option is used with mv command so that the destination file does not get o…”
Quiz questions on cat command, cp command, rm and mv command for deleting and renaming files, comparing files, wc command for counting file data, compressing and archiving files. Ordinary files are the most common type of file in Unix. They contain data that is not associated with any special device or process. Ordinary files can be created, edited, and deleted using standard Unix commands. Here are some of the commands that you can use to manage ordinary files: cat: - Displays the contents of a file. cp: - Copies a file to another location. mv: - Moves or renames a file. rm: - Deletes... Show more
Unix Basics Practice Test: Handling Ordinary Files
Time left 00:00
25 Questions

1. Which command is used for printing a file?
2. Which of the following is not an option of cp command?
3. Which command is used for knowing the file type?
4. Which option is used with rm command for interactive deletion?
5. What is the exit status of cmp command if both the files are identical?
6. Which option is used with cp command for linking files instead of copying?
7. What is the function of cp command in UNIX?
8. What does the following command do?
$ wc sample.txt > newfile
9. Which of the following command is used for viewing the attributes of contents of an archive?
10. When two files are identical, what is the output of diff command?
11. Which option is used with the cat command for displaying file with line numbers?
12. Which option is used for counting the number of characters in a file only.
13. Which of the following is used to compress files?
14. -v option is used with cp command for displaying _____
15. Which command is used for counting words, lines and characters in a file?
16. Which option is used with cmp command to limit the number of bytes to be compared?
17. How can we skip some initial bytes from both the files to be compared?
18. What does the following command do?
cp -u * dir_file
19. Which option is used with cmp command to display a detailed list of mismatches?
20. If the destination file does not exists, then mv command creates it.
21. We can delete multiple files using a single rm command.
22. To create an archive named abc.tar consisting of two files, file01 and file02, which of the following command will be used?
23. Which option performs recursive deletion?
24. Multiple arguments as filenames can be specified in cat command.
25. Which option is used with gzip command to check compression ratio for files?