Sequence of characters that forms a search pattern
"Regex" redirects here. For the comic book, see Re:Gex.
".*" redirects here. For the C++ operator, see Pointer (computer science) § Pointer-to-member.
A regular expression (shortened as regex or regexp),[1] sometimes referred to as rational expression,[2][3] is a sequence of characters that specifies a match pattern in text. Usually such patterns are used by string-searching algorithms for "find" or "find and replace" operations on strings, or for input validation. Regular expression techniques are developed in theoretical computer science and formal language theory.
The concept of regular expressions began in the 1950s, when the American mathematician Stephen Cole Kleene formalized the concept of a regular language. They came into common use with Unix text-processing utilities. Different syntaxes for writing regular expressions have existed since the 1980s, one being the POSIX standard and another, widely used, being the Perl syntax.
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. Regular expressions are supported in many programming languages. Library implementations are often called an "engine",[4][5] and many of these are available for reuse.
^Goyvaerts, Jan. "Regular Expression Tutorial - Learn How to Use Regular Expressions". Regular-Expressions.info. Archived from the original on 2016-11-01. Retrieved 2016-10-31.
^Mitkov, Ruslan (2003). The Oxford Handbook of Computational Linguistics. Oxford University Press. p. 754. ISBN 978-0-19-927634-9. Archived from the original on 2017-02-28. Retrieved 2016-07-25.
^Lawson, Mark V. (17 September 2003). Finite Automata. CRC Press. pp. 98–100. ISBN 978-1-58488-255-8. Archived from the original on 27 February 2017. Retrieved 25 July 2016.
^"How a Regex Engine Works Internally". regular-expressions.info. Retrieved 24 February 2024.
^"How Do You Actually Use Regex?". howtogeek.com. Retrieved 24 February 2024.
and 25 Related for: Regular expression information
A regularexpression (shortened as regex or regexp), sometimes referred to as rational expression, is a sequence of characters that specifies a match...
Perl Compatible RegularExpressions (PCRE) is a library written in C, which implements a regularexpression engine, inspired by the capabilities of the...
regularexpression denial of service (ReDoS) is an algorithmic complexity attack that produces a denial-of-service by providing a regularexpression and/or...
This is a comparison of regularexpression engines. Formerly called Regex++. One of fuzzy regularexpression engines. Included since version 2.13.0. ICU4J...
language theory, a regular language (also called a rational language) is a formal language that can be defined by a regularexpression, in the strict sense...
data sets for lines that match a regularexpression. Its name comes from the ed command g/re/p (global / regularexpression search / and print), which has...
something that will return a value Regularexpression, a means of matching strings of text in computing Expression marks, in music, notating the musical...
as a regularexpression which does not match as parsing expression: [ab]?[bc][cd] is both a valid regularexpression and a valid parsing expression. As...
equations Regular algebra, or Kleene algebra Regular code, an algebraic code with a uniform distribution of distances between codewords Regularexpression, a...
\{a^{i}b^{i}:i\geq 0\}}, the paradigmatic non-regular linear language. Regularexpression, a compact notation for regular grammars Regular tree grammar, a generalization...
syntax. The lexical syntax is usually a regular language, with the grammar rules consisting of regularexpressions; they define the set of possible character...
custom-built, denial-of-service resistant regularexpression engine. In March 2010, the code of RE2, the regularexpression engine used in Google Code Search...
compute the derivative of a generalized regularexpression. Even though originally studied for regularexpressions, the definition applies to arbitrary formal...
the mathematical formalisms called "finite automaton", "regular grammar", or "regularexpression", all of which have the same expressive power. Since the...
associative arrays (that is, arrays indexed by key strings), and regularexpressions. While AWK has a limited intended application domain and was especially...
Conditional Expressions". Archived from the original on 4 June 2013. Retrieved 11 February 2013. "CUBRID 11 Manual - RegularExpressions Functions and...
for the structural complexity of regularexpressions and regular languages. The star height of a regularexpression equals the maximum nesting depth of...
("quick editor", 1965–66). It was one of the earliest tools to support regularexpressions, and remains in use for text processing, most notably with the substitution...
program, such as a shell interpreter or a regularexpression (regex) engine. In POSIX extended regularexpressions, there are 14 metacharacters that must...
programming language. Other notable contributions included his work on regularexpressions and early computer text editors QED and ed, the definition of the...
object-oriented languages such as JavaScript whose patterns are known as regularexpressions. In addition SNOBOL4 strings generated during execution can be treated...
used in the implementation of regularexpressions: Thompson's construction is an algorithm for compiling a regularexpression to an NFA that can efficiently...
escape / in Perl regularexpressions, leading to sequences such as "\/\/"); text becomes difficult to parse through regularexpression they require a mechanism...
integer bitwise like in C. =~ and ==~ can in Groovy be used to match a regularexpression. In Haskell, the tilde is used in type constraints to indicate type...
rule-based approach to create descriptions of malware families based on regularexpression, textual or binary patterns. A description is essentially a YARA rule...