小编som*_*hin的帖子

是否有任何编译器可以将regexp转换为fsm?或者可以转换成人类的话?

可以转换的东西

r"a+|(?:ab+c)"
Run Code Online (Sandbox Code Playgroud)

{
    (1, 'a') : [2, 3],
    (2, 'a') : [2],
    (3, 'b') : [4, 3],
    (4, 'c') : [5]
}
Run Code Online (Sandbox Code Playgroud)

或类似的东西

并在2或5中接受

python regex compiler-construction fsm

8
推荐指数
2
解决办法
207
查看次数

标签 统计

compiler-construction ×1

fsm ×1

python ×1

regex ×1