mardi 25 août 2015

Java regular expression two digit number of group

I test how Java will interprets (one)(one)(one)(one)(one)(one)(one)(one)(one)(one)(two)\11 - it will try to match first group and the literal "1" at the end or it will try to match 11-th group. So it trying to match 11-th group if there is 11-th. But how can I strongly defined this behaviour ? I mean how should I tell that I want to match 11 group always (so when there is no 11 group there is no match). I don't know if this is practicalquestion, I'm just curious. Thanks in advance.



from Newest questions tagged java - Stack Overflow http://ift.tt/1LynpTf
via IFTTT

Aucun commentaire:

Enregistrer un commentaire