
File Comparison and Permission Commands
Authored by Rinchen Tso
Computers
12th Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the comm command do?
The comm command compares two sorted files and shows their differences.
The comm command deletes duplicate lines from a file.
The comm command sorts a single file alphabetically.
The comm command merges two files into one.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you use the diff command to compare two files?
Use the command 'compare file1.txt file2.txt'.
Run 'diff --compare file1.txt file2.txt'.
Use the command 'diff file1.txt file2.txt'.
Execute 'diff file1 file2' without extensions.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the primary difference between the diff and comp commands?
The 'diff' command shows line-by-line differences, while 'comp' provides a general comparison.
The 'diff' command is used for merging files, while 'comp' is for splitting files.
The 'diff' command compares file sizes, while 'comp' checks for identical files.
The 'diff' command shows differences in file permissions, while 'comp' compares file ownership.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the syntax for the chmod command?
chmod -R file mode
chmod [file] [mode]
chmod file mode options
chmod [options] mode file
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What are the three types of file permissions in Linux?
read, write, execute
open, close, rename
create, modify, execute
read, write, delete
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How can you change file permissions using chmod?
Use 'changeperm file' to modify permissions.
Run 'setperm file' to adjust file access.
Execute 'permissions file' to alter settings.
Use 'chmod [options] mode file' to change file permissions.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How can you display only the lines that are different between two files using diff?
diff -q file1.txt file2.txt
diff -c file1.txt file2.txt
diff -i file1.txt file2.txt
diff -u file1.txt file2.txt
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?