Build, test, and debug regular expressions
This regular expression matches duplicate, consecutive words in a text. It captures a word using the `(\w+)` group and then checks if the exact same word follows immediately after some whitespace using the `\1` backreference. It is commonly used for proofreading, data validation, or cleaning up accidental repeated words in documents and paragraphs.