A regexp that does not match itself

-3

Can you think of a regular expression that does not match itself?

Christian

Posted 2015-11-05T20:11:44.693

Reputation: 109

Question was closed 2015-11-05T20:23:12.197

a{2}, and many more – Ypnypn – 2015-11-05T20:19:29.357

Welcome to Protramming Puzzles & Code Golf! I think this question is a bit too broad, there's very many regexpes that doesn't match them self. I would also suggest adding a objective winning criteria, such as code-golf (shortest regexp wins) or popularity contest (answer with the most votes wins). – Loovjo – 2015-11-05T20:21:33.770

^$ - Can't think of shorter for now.. – Optimizer – 2015-11-05T20:22:01.510

This should have been closed as a duplicate of http://codegolf.stackexchange.com/q/22648/194

– Peter Taylor – 2015-11-05T21:28:52.933

Answers

3

A few on 2 chars

^$

\s

\d

\n

\t

\r

And many more consisting of a \ and a lowercase character.

Loovjo

Posted 2015-11-05T20:11:44.693

Reputation: 7 357