Question: Project 1 - 1 2 The cat command has several purposes, but one of the most commonly used is to view the contents of a

Project 1-12
The cat command has several purposes, but one of the most commonly used is to view the contents of a file. For example, in this project, you use the cat command to view a file called shells that resides in the /etc directory. This file contains a list of valid shell programs available through UNIX/Linux.
To use cat to view the shells file:
1. Type cat /etc/shells after the command prompt, and press Enter (see Figure 1-18).(The forward slash (/) is used to indicate a directory or folder change.) What shells do you see on your system?
Figure 1-18 Using the cat command to view the contents of a file
2. Sometimes, it is helpful to see a files contents displayed with line numbers. The -n option causes the cat command to display a number at the beginning of each line of output. Type cat -n /etc/shells and press Enter. You see the same list of shells as before, but this time a number precedes each line.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!