Previous

Next


01. What are Regular Expressions?

  • The term "regular expression" (or "regex") comes from a mathematical background.
  • Something called a "finite state automaton" or "finite state machine" is a model of computation where there exists:
    1. A finite set of states;
    2. A start state;
    3. A set of inputs;
    4. A set of final states; and
    5. A set of transitional states.
  • Regular expressions are a kind of like a way to express this - so that a set of inputs and a start state can be fed into a finite state machine, and a final state obtained.

Previous

Next

Andrew Hill

For LinuxSA Meeting, 21 November 2000