Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Regular expression problem
Using only regular expressions, how do you match the
pattern of the same digit that occurs three times in a string, separated by one character? Examples: 0a0a0 ' 0 occurs three times separated by "a" 9x9x9 ' 9 occurs three times separated by "x" 1:1:1 ' 9 occurs three times separated by ":" Robert |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Regular expression problem
On 24/06/2020 10:47, RG III wrote:
Using only regular expressions, how do you match the pattern of the same digit that occurs three times in a string, separated by one character? Examples: 0a0a0 ' 0 occurs three times separated by "a" 9x9x9 ' 9 occurs three times separated by "x" 1:1:1 ' 9 occurs three times separated by ":" Robert using a global match and a capturing group containing alternation (\d[a|x|:]?){3} Try it on regex101.com -- Adrian C |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Tricky regular expression | Excel Programming | |||
Can someone help me with this regular expression? | Excel Discussion (Misc queries) | |||
Help with regular expression | Excel Programming | |||
Regular Expression | Excel Discussion (Misc queries) | |||
Regular expression searching problem | Excel Programming |