We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.

This lesson's interactive features are locked, please to keep using them

Files

You're probably familiar with the concept of files from using a GUI like Windows Explorer or Finder.

At their core, files are just blobs of data. The raw bytes in a file can represent anything: text, images, videos, etc.

The cat Command

The cat command is used to view the contents of a file. It's short for "concatenate," which is a fancy way of saying "put things together." It can feel like a confusing name if you're using the cat command to view a single file, but it makes more sense when you're using it to view multiple files at once.

# Print the contents of a file to the terminal
cat file1.txt
# Concatenate the contents of multiple files and print them to the terminal
cat file1.txt file2.txt

Assignment

Submit the shell checks.