列出所有正则表达式的可能性 [英] Listing all regexs possibilities
本文介绍了列出所有正则表达式的可能性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一些正则表达式列表,我需要从它们打印所有可能性。
这样:
print abac [ao ]
可打印:
abaca
abaco
这可能吗?
I have some regex lists, and I need to print all possibilities from them.
Like that:
print abac[ao]
that would print:
abaca
abaco
Can this be possible?
推荐答案
我会说是的。你试过了什么?
- 凯文
I would say yes. What have you tried?
--Kevin
是的,但它没有用:
Yeah, but it didn''t work:
perl -e''print" abac [ao] \ n"''
abac [ao]
perl -e ''print "abac[ao]\n"''
abac[ao]
这篇关于列出所有正则表达式的可能性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文