what is the difference between SED and GREP ?
Which one is more better and why?

Answers were Sorted based on User's Feedback



what is the difference between SED and GREP ? Which one is more better and why?..

Answer / gogune suresh kumar

Both serves the purpose of "pattern matching" in files.
SED has more features compared to simple GREP. Ex: like
replacement of existing string with new string. Deleting the
lines in a file etc.

Is This Answer Correct ?    57 Yes 5 No

what is the difference between SED and GREP ? Which one is more better and why?..

Answer / ravi mahant

SED has more features compared to simple GREP. we can grep
and edit and replace string using SED.
GREP is used to find the string and active process.

Is This Answer Correct ?    30 Yes 7 No

what is the difference between SED and GREP ? Which one is more better and why?..

Answer / kiruthiga.s

SED-- search and replace


grep filters the matching pattern

Is This Answer Correct ?    13 Yes 1 No

what is the difference between SED and GREP ? Which one is more better and why?..

Answer / basanth

grep has only pattern space since it can store only one line at a time but sed has pattern space and hold space.it can store more than one line at a time

Is This Answer Correct ?    13 Yes 5 No

Post New Answer

More Unix Commands Interview Questions

1-how will you display a file whose name is starting with '- '? 2-how will you add a patten at end of every line in vi editor?

7 Answers  


how to sort the content of the file based on numeric values

0 Answers   Epsilon,


How to get the operating system's information in unix?

6 Answers   IBM, TCS,


What is the command to compare two files in unix?

0 Answers  


what is the difference between relative path and absolute path?

7 Answers  






how will you convert a general file to a hidden file?

4 Answers  


what are the different commands used to view the contents of a file?

5 Answers  


How to display a file name which has zero bytes in size.

11 Answers   Polaris,


What is a bash command?

0 Answers  


boot process?

2 Answers   Atos Origin, Wipro,


How to convert a hidden file to normal visible file?

8 Answers  


Why is it called a shebang?

0 Answers  


Categories