Write a command to print the line numbers along with the line that has the word “july”?

grep -n july filename
The ‘-n’ option is used to print the line numbers in a file. The line numbers start from 1

Be the first to comment

Leave a Reply

Your email address will not be published.


*