grep is one of the most useful and powerful commands in Linux for file processing. grep searches one or more input files for lines that match a regular expression and writes each matching line to standard output.
Source: LXer – Regular Expressions in Grep