Regular expressions are a notation system for regular languages: for every
regular language there is a regular expression that denotes it (in fact, there are
infinitely many). Unlike finites state machines, regular expressions are
concise and can be easily written out by a human being. More importantly, they
can also be typed on a command line, and thus can be used easily as input to
programs. Hence, regular expressions have become a standard tool to
describe patterns of strings in such programs as editors or search algorithms.
Finite automata and Regular
Expressions