Instead of matching the whole string against a regular expression, check whether it contains a matching substring.
This can be done by changing the matcher to activate initial symbols in every step rather than only in the first step. The algorithm can be stopped if there is a final expression in a list of expressions generated by scanl.
Instead of matching the whole string against a regular expression, check whether it contains a matching substring.
This can be done by changing the matcher to activate initial symbols in every step rather than only in the first step. The algorithm can be stopped if there is a final expression in a list of expressions generated by
scanl
.