Multiple choice

Which of the following file commands is used to identify the type of a file by context?

  1. ls

  2. Cat

  3. File

  4. More

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

The file command analyzes a file's contents and determines its type based on the file's magic numbers and content structure, not just the extension. This is useful for identifying unknown files.