1. : A directory can be deleted by which command if it is not empty?
(A) rm -r
(B) rmdir
(C) rm *
(D) del *
2. : What option do we use with the mv command so that the destination file is not overwritten?
(A) -n
(B) -f
(C) -b
(D) -i
3. : The command used for renaming the files is _____
(A) rename
(B) mv
(C) cp
(D) move
4. : What will happen if the destination file specified in mv command already exists?
(A) it will be deleted
(B) it will not be affected
(C) it will be overwritten
(D) an error will occur
5. : Apart from renaming the files, mv command can ____
(A) move a file
(B) move a group of files
(C) rename a directory
(D) also move the group of files and rename the directory
6. : When -f option is used with mv command, this overwrites the existing files with no prompting messages.
(A) True
(B) False
(C) Partially True
Answer: (A) True
7. : To remove/delete files in UNIX, what command do we use?
(A) rmdir
(B) rm
(C) del
(D) mv
8. : By using the single rm command, multiple files can be deleted.
(A) True
(B) False
(C) Partially True
Answer: (A) True
9. : What do we use for deleting all files in a directory?
(A) rmdir *
(B) mv *
(C) rm *
(D) del *
10. : What option can we use with rm command if we wish to delete or remove a file forcefully?
(A) -i
(B) -r
(C) -R
(D) -f
11. : To remove file named -file.txt, what command do we use?
(A) rm -file.txt
(B) rm file.txtrm
(C) rm — -file.txt
(D) rm -f file.txt
12. : The inode number associated with a file is changed after renaming it.
(A) True
(B) False
(C) Partially True
Answer: (B) False
13. : To backup the destination file in mv command, what option do we use?
(A) -b
(B) -f
(C) -v
(D) -i
14. : By using rm command, because of permissions associated with it, some files are not deleted.
(A) True
(B) False
Answer: (A) True
15. : With rm command, for interactive deletion, what option do we use?
(A) -i
(B) -f
(C) -r
(D) -R
16. : Recursive deletion is performed by ____
(A) -r
(B) -R
(C) *
(D) -r and -R