Linux Essentials (010-150) — Question 5

Which of the following commands can be used to view a file and do search operations within it while viewing the contents?

Answer options

Correct answer: A

Explanation

The correct answer is 'less' because it is a command-line utility that allows users to view the contents of a file with the ability to scroll and search through it. The 'find' command is used to search for files in a directory, 'grep' is for searching text within files, and 'report' and 'see' are not standard commands for viewing files.