Test, validate and match regular expressions
Matches runs of one or more identical lowercase letters using a named capture group 'ch' for the first letter and a backreference \1 to consume any consecutive repetitions. With the global flag it finds all such runs in a string, e.g., 'aabcc' yields 'aa', 'b', 'cc'. Useful for run-length encoding, counting consecutive characters, or splitting strings into groups of repeated letters.