When is a issue too complex for a regular expression?

后端 未结 13 1012
执念已碎
执念已碎 2021-02-01 19:42

Please don\'t answer the obvious, but what are the limit signs that tell us a problem should not be solved using regular expressions?

For example: Why is a complete emai

13条回答
  •  灰色年华
    2021-02-01 20:17

    Along with tremendous expressions, there are principal limitations on the words, which can be handled by regexp. For instance you can not not write regexp for word described by n chars a, then n chars b, where n can be any, more strictly alt text.

    In different languages regexp is a extension of Regular language, but time of parsing can be extremely large and this code is non-portable.

提交回复
热议问题