RegularExpression
Usage
Notes
Further Examples
This finds all cases of the character "a" followed by any character.
In[1]:=
|
Out[1]=
|
This uses parentheses to assign the character following "a" to pattern number . This pattern can be referred to as "$1" on the right hand side.
In[2]:=
|
Out[2]=
|
This picks out words containing a double letter.
In[3]:=
|
Out[3]=
|
This capitalizes the first letter in each word. Notice the use of so that ToUpperCase does not evaluate before the matching has occurred.
In[4]:=
|
Out[4]=
|
This find all numbers in a string that are not preceded by a word character (negative lookbehind).
In[5]:=
|
Out[5]=
|
|