[Syllabus] [Previous Lecture] [Next Lecture]

Regular expressions

Regular expressions come in many forms. The syntax we use in class is much simpler than the syntax used by, say, the UNIX grep command, but both have equivalent descriptive power. (grep, by the way, is even used at the North Pole.)

Here's a nice description of regular expressions in UNIX, specifically in regexp, and here's a more detailed explanation.

Here are UNIX man (manual) pages for regexp and for grep, egrep, and fgrep ( link1, link2, link3). Regular expressions are used for searching in a number of editors such as ed, vi, and emacs. They have found their way into programming languages such as Tcl and Perl. Here's a paper on specifying search expressions in Perl, and here's one on using Perl to search the Web. Here's yet another writeup on using regular expressions in Perl.

Copyright © 1996 by David Matuszek
Last modified Feb 4, 1996