what is the function of grep command?

Answers were Sorted based on User's Feedback



what is the function of grep command?..

Answer / khemnath chauhan

grep command let us find the desire pattern in given
statements or from contents of file.
SYNOPSIS:
$grep <pettern to search> <file name>
this will find the particular pattern.

Is This Answer Correct ?    9 Yes 0 No

what is the function of grep command?..

Answer / bharath

grep command is used to search a string or a keyword in a
file.
syntax:
grep 'keyword' file

Is This Answer Correct ?    6 Yes 3 No

what is the function of grep command?..

Answer / dhina

Grep will help us to display the particular information from
a file. For example.

grep apple fruitlist.txt

In this case, grep prints all lines containing 'apple' from
the file fruitlist.txt

Is This Answer Correct ?    3 Yes 0 No

what is the function of grep command?..

Answer / kavin

grep is used to filter or search for a pattern in the given
file.

for example
grep student class

will display only the lines that contains the word student
in it.

Is This Answer Correct ?    4 Yes 1 No

Post New Answer

More Unix Commands Interview Questions

What is command substitution?

0 Answers  


Explain the steps that a shell follows while processing a command.

0 Answers  


distinguish between user mode and kernel mode?

4 Answers   Infosys,


What is grep and sed command?

1 Answers  


How do you repeat a command in terminal?

0 Answers  






what is kernel?

6 Answers  


How do I use grep to search for a file?

0 Answers  


What is the nmap command?

0 Answers  


what is the use of uniq commmand?

8 Answers  


How do I clear my terminal history?

0 Answers  


what is the command to list all files in a directory, including the hidden files in UNIX ?

9 Answers   CTS,


How to convert a hidden file to normal visible file?

8 Answers  


Categories