Build, test, and debug regular expressions
Matches any line that does NOT contain the substring 'test'. It works by consuming one character at a time, checking a negative lookahead ((?!test)) at each position to ensure the forbidden word never starts there, with ^ and $ anchoring the pattern under the multiline flag so each line is validated independently. Commonly used for inverse searches (like grep -v) in tools that lack built-in negation, e.g., filtering log lines that exclude a keyword.