http://regex.alf.nu/ 非标准答案

  1. Plain strings (207)                             foo
  2. Anchors (206)                                     ick$
  3. Ranges (202)                                     [a-f]{4}
  4. Backrefs (201)                                   (...).*\1
  5. Abba (190)                                          ^((?!(.)(.)\3\2).)+$
  6. A man, a plan (176)                          ^(.)(.).*\2\1$
  7. Prime (286)                                        ^(?!(xx+)\1+$)
  8. Four (199)                                           (.)(.\1){3}
  9. Order (199)                                         ^.{5}[^e]?$
  10. Triples (574)                                       ^(([147]4|40|3[269]|9[05]|[378]1).+|0[369]*|[81][257])*$
  11. Glob (384)                                           (rr|ll|[lbr]o|en|ta|y|cr|eat|up).*\1
  12. Balance (287)                                    ^(<(<(<(<(<(<.*)*>)*>)*>)*>)*>)*$
  13. Powers (80)                                       ^(((x|x{8}|x{128})\3?)\2?)\1?$
  14. Long count (239)                              ((..)00 \2+01 \2+10 \2+11 ?){4}
  15. Long count v2 (239)                         ((..)00 \2+01 \2+10 \2+11 ?){4}
  16. Alphabetical (0)
posted @ 2014-01-19 13:25  xindoo  阅读(243)  评论(0编辑  收藏  举报