Advanced

Regex Golf

Write one regular expression that matches every "must match" string and none of the "must not match" ones.

Must match

    Must NOT match

      About this tool

      A quick way to practise regex thinking — inspired by the classic "regex golf" challenge popularised by xkcd. Green means matched, red means didn't; solve the puzzle by getting every "must match" green and every "must not match" red.