TOPICS
Search

Substring


A substring is a contiguous block of symbols within a string. Equivalently, a string v is a substring of u iff u=avb for some strings a and b, either of which may be empty (CRC Press LLC 2004).

For example, bc is a substring of abcd, whereas ac is a subsequence of its symbols but is not a substring. The term subword permits nonconsecutive symbols in the convention used for the Bruhat order. A substring of a word is also called a factor.


See also

Shortest Common Superstring, String, Subsequence, Subword, Word

Explore with Wolfram|Alpha

References

CRC Press LLC. "Substring." In Dictionary of Algorithms and Data Structures (Ed. P. E. Black). National Institute of Standards and Technology, Dec. 17, 2004. https://xlinux.nist.gov/dads/HTML/substring.html.

Cite this as:

Weisstein, Eric W. "Substring." From MathWorld--A Wolfram Resource. https://mathworld.wolfram.com/Substring.html

Subject classifications