Help with regular expression to replace reoccurring characters in a string

Hello guys,
Please help me with a simple regular expression for this . I want to replace reoccurring “^” in a string to empty.
i.e
INIT^^^ = INIT^
INIT^ = INIT^
^^INIT^ = ^INIT^
I need a regular expression that would pick the ^ anytime the character appear more than once following each other

Regards

You can try the following regex

1 Like

Regex will be
(\^)\1+

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.