Regex: match pattern as long as it’s not in the beginning

You can use a look behind to make sure it is not at the beginning. (?<!^)aaa

Leave a Comment