Test, validate and match regular expressions
The famous 'prime regex': matches any line whose length is NOT prime. The .? branch matches lengths 0 and 1, while (..+?)\1+ uses a lazy-captured block of at least 2 characters repeated 2+ times, proving the length is composite. Feed it a string of repeated characters (e.g., 'aaaa') and negate the match to test primality — a classic demonstration of backreference math tricks.