Grep (Global Regular expression Print) searches for any string in a list of strings or files. Grep command understand two different versions of regular expression syntax like basic and extended. Another version of grep is egrep (Extended grep). It searches for a pattern using extended regular expressions. A regular expression followed by a +,?,|, (), the newline character will not be matched by the regular expression.  Egrep is same as grep command with -E flag, expect that error and usage message are different and also -s flag functions. In egrep, command lines are limited to 2048 bytes and input lines should not contain the NULL character and also input files should end with a newline character.