Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to find files named 'report.txt' in the current directory.
Linux CLI
find . -name [1] Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Not using quotes causes the shell to interpret the pattern incorrectly.
Using no quotes may fail if the filename contains special characters.
✗ Incorrect
The find command requires the name pattern in quotes to avoid shell expansion. Single quotes are safest.
2fill in blank
mediumComplete the code to find directories named 'backup' anywhere under /home.
Linux CLI
find /home -type [1] -name 'backup'
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using '-type f' finds files, not directories.
Using an invalid type causes no results.
✗ Incorrect
The '-type d' option tells find to look for directories only.
3fill in blank
hardFix the error in the code to find files larger than 10MB named 'data.log'.
Linux CLI
find /var/log -name 'data.log' -size [1]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using '10M' finds files exactly 10MB, not larger.
Using '-10M' finds files smaller than 10MB.
✗ Incorrect
The '+10M' means files larger than 10 megabytes. Without '+', it means exactly 10MB.
4fill in blank
hardFill both blanks to find symbolic links named 'config' smaller than 1KB.
Linux CLI
find /etc -type [1] -name [2] -size -1k
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using '-type f' finds files, not links.
Not quoting the name can cause errors.
✗ Incorrect
Use '-type l' for symbolic links and quote the name 'config' to match exactly.
5fill in blank
hardFill all three blanks to find regular files named 'log.txt' larger than 5MB in /var.
Linux CLI
find /var -type [1] -name [2] -size [3]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using '-type d' finds directories, not files.
Not quoting the filename causes errors.
Using '5M' finds files exactly 5MB, not larger.
✗ Incorrect
Use '-type f' for files, quote the name, and '+5M' for files larger than 5MB.