When i use the regex IID:\s*\d*0
to match ID: 12344y
the regexbuddy give me the result
https://raw.github.com/litsand/litsand.github.com/master/_posts/pic/4.png
it backtrack \d*
to find the match ,but don't backtrack the \s*
when i change the regex to ID:\s*\d*q
,it don't backtrack anymore.and give me the fail message.
https://raw.github.com/litsand/litsand.github.com/master/_posts/pic/5.png
I know even if it backtrack ,finally the regex would give me a fail message. But how the regexbuddy knew it would fail and don't backtrack?
I read the Mastering Regular Expressions and don't find any answer. thanks for your help.
Sorry for the pictures,I don't have the right to upload image.