

Regular expressions originated in 1951, when mathematician Stephen Cole Kleene described regular languages using his mathematical notation called regular events. Stephen Cole Kleene, who introduced the concept Most general-purpose programming languages support regex capabilities either natively or via libraries, including Python, C, C++, Java, Rust, OCaml, and JavaScript. Regular expressions are used in search engines, in search and replace dialogs of word processors and text editors, in text processing utilities such as sed and AWK, and in lexical analysis. Different syntaxes for writing regular expressions have existed since the 1980s, one being the POSIX standard and another, widely used, being the Perl syntax. They came into common use with Unix text-processing utilities. The concept of regular expressions began in the 1950s, when the American mathematician Stephen Cole Kleene formalized the concept of a regular language. Regular expression techniques are developed in theoretical computer science and formal language theory. Usually such patterns are used by string-searching algorithms for "find" or "find and replace" operations on strings, or for input validation. ) (?= ) At least two spaces are matched, but only if they occur directly after a period (.) and before an uppercase letter.Ī regular expression (shortened as regex or regexp sometimes referred to as rational expression ) is a sequence of characters that specifies a search pattern in text. If you already know the feature you want but forgot which syntax to use, look up the feature in the regex reference table of contents instead.(? < = \. Since the full reference tables cover a variety of regex flavors, this quick reference may have multiple entries for the same syntax with links to different sections in the tutorial if different regex flavors use the same syntax for different features.


Follow the link to learn more about the syntax in the tutorial. You can use this table if you’ve seen some syntax in somebody else’s regex and you have no idea what feature that syntax is for. This quick reference is a summary of all the regex syntax that is listed in the full reference tables, without any explanation.
