In UNIX and Unix-like operating systems, a filter is program that gets most of its data from standard input (the main input stream) and writes its main results to standard output (the main output stream). UNIX filters are often used as elements of pipeline (Unix)s. The pipe operator ( | ) on a command line signifies that the main output of the command to the left is passed as main input to the command on the right.
The classic filter would be
Grep, which at it simplest prints to its output any lines containing a character string. Here s an example:
cut -d : -f 1