Content deleted Content added
FlaxenHobbit (talk | contribs) →Border: Fixed typo. Tags: Reverted Mobile edit Mobile web edit Advanced mobile edit |
FlaxenHobbit (talk | contribs) →Substring: Hyphenated per MOS:HYPHEN Tags: Reverted Mobile edit Mobile web edit Advanced mobile edit |
||
Line 25:
The first occurrence is obtained with <math>p=</math><code>b</code> and <math>s=</math><code>na</code>, while the second occurrence is obtained with <math>p=</math><code>ban</code> and <math>s</math> being the empty string.
A substring of a string is a [[#Prefix|prefix]] of a [[#Suffix|suffix]] of the string, and equivalently a suffix of a prefix; for example, <code>nan</code> is a prefix of <code>nana</code>, which is in turn a suffix of <code>banana</code>. If <math>u</math> is a substring of <math>t</math>, it is also a [[subsequence]], which is a more general concept. The occurrences of a given pattern in a given string can be found with a [[string
In the mathematical literature, substrings are also called '''subwords''' (in America) or '''factors''' (in Europe). {{citation needed|date=November 2020}}
|