Oh boy what a beautiful regex. I'm sure it does something logical and easy to understand.
Oh boy what a beautiful regex. I'm sure it does something logical and easy to understand.
^.?$|^(..+?)\1+$
<answer>
Matches strings of any character repeated a non-prime number of times
You're viewing a single thread.
View all comments
83
comments
It matches for non-primes and doesn't match for primes.
2 0 Reply
You've viewed 83 comments.
Scroll to top